No way to disable functions locally in isolated mode based on different environments (only using local.settings.json)

Description
We are currently migrating a .NET 6 in-process function app to isolated mode, and are running into issues when trying to disable functions during local development. Our requirements are to disable certain functions in some local environment settings, but enable them for others. Thus, simply putting stuff into the local.settings.json is no solution for us.
With the old in-process libs, we were using [Disable("Setting")] Attributes on the functions we wanted disabled, and we were configuring those settings in appsettings.<Environment>.json files we added during function startup using the regular AddJsonFile configuration extensions. The [Disable] Attribute does not work any more (at least currently not, related #312 and #438). And using the AzureWebJobs.<FunctionName>.Disabled approach only works, when putting those settings into the local.settings.json. It seems that somehow, all Functions are already loaded and configured before any HostBuilder user code executes. That means, adding any configuration in ConfigureHostConfiguration or ConfigureAppConfiguration is too late and will not disable any functions. We are not sure if this is by design, but it seriously constraints any dynamic configuration of functions when developing locally.
Expected behavior
We would expect to have any way to disable functions during startup with a more dynamic mechanism except the local.settings.json, depending on the configured environment.
Actual behavior
There is no way to locally disable functions by configuration except local.settings.json, at least none we found.
Known workarounds
We could use compiler flags and combine different environment with those compiler flags, to simply remove the affected functions from the code.
App Details

Functions versions:
Microsoft.Azure.Functions.Worker 1.10.0
Microsoft.Azure.Functions.Worker.Sdk 1.7.0
Microsoft.Azure.Functions.Extensions.Http 3.0.13
Microsoft.Azure.Functions.Extensions.Timer 4.1.0
Azure Functions runtime version: v4
Programming language used: C#

You're correct that this is a limitation with the existing model, but with the metadata generation updates, where the worker is responsible for the function metadata, this will be supported.
Flagging this for validation with the source generation model.
High level tasks associated with this:

[ ] Define the disabled attribute on the worker, with support for conditions based on configuration
[ ] Ensure the metadata generator is using the attribute and evaluating conditions
[ ] Ensure the host is properly handling the disabled flag sent with the function metadata.

You're correct that this is a limitation with the existing model, but with the metadata generation updates, where the worker is responsible for the function metadata, this will be supported.
Flagging this for validation with the source generation model.
High level tasks associated with this:

[ ]  Define the disabled attribute on the worker, with support for conditions based on configuration
[ ]  Ensure the metadata generator is using the attribute and evaluating conditions
[ ]  Ensure the host is properly handling the disabled flag sent with the function metadata.

Do we have ETA for this? We really need this 'Disable' functionality before we migrate to isolated mode.

Thank you for the follow up, @Zoe1808 . We don't have an ETA to share as this issue has not been assigned due to competing priorities.
@satvu let's follow up on this so we can scope the work, as this could be done with enhancements to the generator.

Are there any recent updates to this issue? My team is facing the same problem and the workarounds aren't very tenable.

@fabiocav Thank you for the progress on this issue. My team shares the same problem as @TomHutsonVantage and we would like a maintainable way to disable timer triggers per environment or altogether.

We have the same problem

Our team has the same issue.

Have the same issue.

Was revisiting isolated functions now that .net 8 is coming out (isolated was supposed to be the only/primary path in the roadmap with .net 8) and I believe this issue is one of the last remaining issues, now that we finally have better support handling ServiceBus messages and the Application Insights story has improved.
@fabiocav , any updates or traction on this issue?

This is also the thing which is restricting us to moving to the latest version.

@fabiocav what about the disabled attribute that currently exists in non-isolated.  See #9693 for more details on why this is different than using local settings.
Basically, though, local settings is not part of source control and would require some other way to synchronize for new devs or cloned projects. Much less new functions that are added and then kick off when the repo is sync'd but the settings are outdated.
The use case being, I almost never want my local environment to process every queue and timer trigger. I have functions apps with 30 and 40 functions on these triggers. It's much easier to
#IF DEBUG
[DISABLE()]
Please do not remove this from isolated.

@fabiocav I agree with @tbasallo. The use of #IF DEBUG is straightforward in the dev environment and does not require adjusting local settings if you decide to change a function name, etc.

This is a very common pattern when running locally.
Similar to Timer triggered functions with RunAtStartup surrounded by #if DEBUG pre-processor directive to ensure a timer is executed upon execution.

@Schmaga I'm assuming you were injecting your configuration with a startup in the in-proc model, but that may lead to issues depending on the hosting model you're using (can you confirm what plan you use for your apps).

We are currently using .NET 7 Isolated mode functions. And yes, we are injecting those configuration settings with a Startup. Either using AddJsonFile in local environments, or via the AppConfiguration integration in Azure hosting scenarios.

Additional folks on the issue, to summarize, if we go down this path, the following would be required to disable functions:

For hosted scenarios, an app setting following: AzureWebJobs.<FunctionName>.Disabled would be used
For local development, app settings are defined as environment variables in either local.settings.json or launch configuration.

Would this mean that the approach using settings injected via the AppConfiguration provider would not work, instead we would always have to add them to the app settings of the App Service?

Would this mean that the approach using settings injected via the AppConfiguration provider would not work, instead we would always have to add them to the app settings of the App Service?

If we continue with the plans mentioned above, yes, that would be the case.
I am curious about your current in-proc setup, though. What hosting model are you running on?
We had a review of this issue today, and we do believe the root of the problem here is really around better configuration (as opposed to just supporting the disabled attribute model), and more significant configuration changes are required to address a few issues, including the local development flow.

Sorry for the delayed response to this, i have only just come back from holiday.
@fabiocav, I don't think that solution really fixes the underlining problem which has been introduced from the isolated worker model.
I say this because the entire reason for why people are using the appsettings and disabled attribute to enable/disable azure function triggers, is it to seperate concerns between infrastructure and development. In the above solution, for the isolated worker model, your still requiring either developers to have direct access to an Azure app plan, so they can enable/disable any new azure function triggers they build or your slowing everyones development processes down because now every time a developer wants to create a new trigger, they now need to run it past the infrastructure team to add the configuration in for every environment, plus any changes in the future.
The original way this worked with the in-process model allowed developers to create a new azure function triggers and define if it should be running in differernt environments, simply by adjusting the configuration files in the solution. The developers did not need direct access to an azure app plan and thus the CICD could handle the deployment behind the scenes. This works well because both the scheduled timestamps for any azure function trigger jobs and its environmental configuration were both handled in the same place.
Unfortantely, this is the exact reason we currently cannot migrate to the isolated worker model and are stuck on a lower .NET version.

I am curious about your current in-proc setup, though. What hosting model are you running on?

We are used the isolated mode hosting model. Or do you mean something else by hosting model?

Thanks, @wc-whiteheadd
@Schmaga my question was about the application you're migrating from. You've described what you're doing with your in-proc app, and the challenge getting the same to work with isolated. For the in-proc app, what hosting model are/were you using (consumption, elastic premium, dedicated, etc.)?

@Schmaga my question was about the application you're migrating from. You've described what you're doing with your in-proc app, and the challenge getting the same to work with isolated. For the in-proc app, what hosting model are/were you using (consumption, elastic premium, dedicated, etc.)?

Ah, now I understand. We are using a dedicated app service plan for hosting. Have been for the in-proc app, and still are for the isolated mode app.

Same here. Also migrating to .NET 8 Isolated and this is a blocker for us 😞 (and .net 6 is deprecated ending this year)

I hate to be harsh but is there any updates on this as its technically now been an issue since November 2022, also this ticket has been marked with "enhancement" which is wrong considering its literally blocking people from migrating to it, especially when the .NET 6 deprecation date is coming closer.
Do we have any timescales on when its going to be resolved or the work which is ongoing to solve it?

Stuff like this really adds to the confusion between the isolated and in process models. I've struggled enough finding good documentation for the isolated model, and was really taken aback at how simple functionality like this has been skipped over this far.

That feature is definitely a blocker. A lot of products are complaining of this to be able to migrate.

It would also be nice to have a single configuration value to disable ALL functions in a function app.
I don't want my staging slot, which is running an n-1 version of the function, to be processing my queues.

just to update, I have now raised this with our MS Azure account manager because there is still no information about the progress on this and the business window is getting smaller to migrate our solutions away from the deprecated version of .NET, leaving us little planning time. The support end date for .NET 6 is "Nov 12, 2024", which is the version most people are limited to until this issue is resolved.

Ahh... always nice to have a smooth sailing .NET upgrade until you find that ONE single thing that blocks you.
THANKS MICROSOFT. Now I have to split up all the functions for each environment.
@fabiocav please update tags to make this more urgent. Would love to see this as a bug instead of an enhancement, as per every other comment in this Issue.

@fabiocav
Our scenario, which I think is quite common, is that our staging deployment slot has an setting TIMERS_DISABLED on it (to stop the timer triggers running in this slot), and then in our function app, all of our 20+ timer triggers are decorated with:
[Disable("TIMERS_DISABLED")]
Your proposed approach of requiring a specific environment variable for each function, would introduce a lot of overhead here given that generally, the intent is to disable all the timers in a given deployment slot.
In fact I would think you could deal with 90% of the requests for this by just supporting a standard well-known environment variable called something like FUNCTIONS_DISABLE_TIMERS which, when set, would prevent all timer triggers from firing

In fact I would think you could deal with 90% of the requests for this by just supporting a standard well-known environment variable called something like FUNCTIONS_DISABLE_TIMERS which, when set, would prevent all timer triggers from firing

I agree with this sentiment, except I would expand it to include queue triggers, storage triggers, or any other type of trigger that polls or monitors instead of just being a type of webhook.

I mocked up a possible solution using middleware that works for timer triggers.  In local testing the runtime still tries to invoke the function but the body of the function itself is not reached, so this may still count towards function execution counts for billing purposes
This can probably be extended towards other trigger types, but they may have other requirements like setting specific response values
Program.cs
.ConfigureFunctionsWorkerDefaults((IFunctionsWorkerApplicationBuilder workerApp) => {
    workerApp.UseWhen<DisableFunctionMiddleware>((context) => {
        return DisableFunctionMiddleware.CheckFunctionEnforcement(context);
    });

})

Sample Trigger Function
[Function("TimeFunction")]
public void Run([TimerTrigger("*/30 * * * * *")] TimerInfo myTimer)
{
    _logger.LogInformation($"C# Timer trigger function executed at: {DateTime.Now}");

}

Middleware
internal class DisableFunctionMiddleware: IFunctionsWorkerMiddleware
{
    private IGlobalLoggingService _logger;
    public async Task Invoke(FunctionContext context, FunctionExecutionDelegate next)
    {
        ResolveDependencies(context);

        if (!IsTriggerDisabled())
        {
            await next(context);
        }
        else {
            //not calling next(context) will prevent the function from being executed
            _logger.LogInformation($"Function {context.FunctionDefinition.EntryPoint} is disabled");
        }

    }
    private void ResolveDependencies(FunctionContext context)
    {
        _logger = (IGlobalLoggingService)context.InstanceServices.GetService(typeof(IGlobalLoggingService))!;

    }
   //exposed so we only apply the middleware to TimerTrigger functions
    public static bool CheckFunctionEnforcement(FunctionContext context)
    {
        // We want to use this middleware only for http trigger invocations.
        bool isTimerTrigger = context.FunctionDefinition.InputBindings.Values
                        .First(a => a.Type.EndsWith("Trigger")).Type == "timerTrigger";
        return isTimerTrigger;

    }
    private bool IsTriggerDisabled() {
        return true; //add what ever conditions you want (reflection checks, config settings etc)
    }
}

@elliot-j This is a good workaround for the timer trigger.

This can probably be extended towards other trigger type

Unfortunately, it won't work for triggers such as service bus trigger, where invocations should not be happening at all. Trying to resolve those from the middleware will cause messages to go into the dead-letter queue, which will cause other problems.

@fabiocav @pragnagopa @mumurug-MSFT
The .net6 deadline is fast upon us. This is a huge blocker for us since this adds an additional complication and a solution finding exercise and thus more work than what isolated-mode is already requiring.
This is still considered an enhancement, when it should be a bug or regression since it's something that was working and is no working for a required migration.
There has been plenty of questions and issues related to this. And I am sure there are quite a few orgs that don't even realize this will be an issue because they're procrastinating the migration and are (naively) assuming this will be available.
Can we get an update on this removed feature? What's the plan for supporting it, if any? And what that timeline looks like.
Some related issues:
#9229, #9751, #2412, #9693

Perhaps an easy solution would be to let program.cs control the registration/setup of all triggers.   Instead of automatically setting up every trigger, let us have some control over it - so in the case of disabling all triggers in a staging slot - would be able to just not register them.
This particular issue has been a blocker of .net isolated since it was announced and the appears to be no workaround at this time short of putting a disabled config setting for every function into the staging slot.    This however does not help with development scenarios, etc.

Sharing our workaround...

We defined our own attribute: [DisableFunction]

[AttributeUsage(AttributeTargets.Method, AllowMultiple = false)]
public class DisableFunctionAttribute : Attribute, IFilterMetadata
{
    public DisableFunctionAttribute(string settingName)
    {
        this.SettingName = settingName;
    }

    internal string SettingName { get; }
}

As currently the default function indexing is worker indexing, so we added a custom Function metadata provider and ensure this is registered as the last IFunctionMetadataProvider, so we could get the function metadata from the default provider and filter with our attribute. In this case, functions with [DisableFunction] attribute will not be indexed.:

public class CustomFunctionMetadataProvider : IFunctionMetadataProvider
{
    private readonly IServiceProvider sp;

    public CustomFunctionMetadataProvider(IServiceProvider sp)
    {
        this.sp = sp;
    }

    public Task<ImmutableArray<IFunctionMetadata>> GetFunctionMetadataAsync(string directory)
    {
        var service = this.sp.GetServices<IFunctionMetadataProvider>().ToList();
        var functionMetadataProvider = service.Last(x => x.GetType() != typeof(CustomFunctionMetadataProvider));

        var metadataList = new List<IFunctionMetadata>();
        Task<ImmutableArray<IFunctionMetadata>> list = functionMetadataProvider.GetFunctionMetadataAsync(directory);

        HashSet<string> disabledFunctions = new HashSet<string>();
        var scriptFiles = list.Result.Select(fn => fn.ScriptFile).ToHashSet();
        foreach (var item in scriptFiles)
        {
            Type[] types = Assembly.LoadFrom(item).GetTypes();
            var methods = types.SelectMany(t => t.GetMethods()).Where(m => m.GetCustomAttributes(typeof(DisableFunctionAttribute)).Any() && m.GetCustomAttributes(typeof(FunctionAttribute)).Any());
            foreach (var method in methods)
            {
                string disableSetting = method.GetCustomAttribute<DisableFunctionAttribute>().SettingName;
                if (IsSettingEnabled(disableSetting))
                {
                    disabledFunctions.Add(method.GetCustomAttribute<FunctionAttribute>().Name);
                }
            }
        }

        foreach (var item in list.Result)
        {
            if (!disabledFunctions.Contains(item.Name))
            {
                metadataList.Add(item);
            }
        }

        return Task.FromResult(metadataList.ToImmutableArray());
    }

    private static bool IsSettingEnabled(string settingName)
    {
        // check the target setting and return false (disabled) if the value exists and is "falsey"
        string value = Environment.GetEnvironmentVariable(settingName);
        if (!string.IsNullOrEmpty(value) &&
            (string.Compare(value, "1", StringComparison.OrdinalIgnoreCase) == 0 ||
             string.Compare(value, "true", StringComparison.OrdinalIgnoreCase) == 0))
        {
            return true;
        }

        return false;
    }
}

@fabiocav @pragnagopa @mumurug-MSFT @SeanFeldman
Hello team - not trying to be a pain, but the in-process model deadline is getting closer, and this issue has not received enough attention. This issue is detrimental to developers that have functions that kick off with timers or events - what's the proposed solution?
How does Microsoft and the Azure Functions team expect developers to work on a project locally with these triggers firing off? While timers can be handled using a few methods, others like service bus, queues, blobs, etc. will end up in an undesirable state - and probably unbeknownst to them.

@Zoe1808 I'm looking to do something similar.  Do you just register your CustomFuntionMetadataProvider during HostBuilder.ConfigureServices like this?
services.AddSingleton<IFunctionMetadataProvider, CustomFunctionMetadataProvider>();

@Dan-Christ-Aya Yes. And you need to ensure ConfigureServices is called after ConfigureFunctionsWorkerDefaults (DefaultFunctionMetadataProvider is registered in ConfigureFunctionsWorkerDefaults)

@Dan-Christ-Aya Yes. And we need to ensure ConfigureServices is called after ConfigureFunctionsWorkerDefaults (DefaultFunctionMetadataProvider is registered in ConfigureFunctionsWorkerDefaults)

The finding of @JeroenvdBurg On swapping between slots the functions which are disabled in the slot will shortly be turned on during swap. causes unintended side effects and should be classified as a bug rather than an enhancement. At the very least, this behavior needs to be documented clearly.

Is there any update or known schedule on this? My team also come to the same issue as we are migrating the existing .net 6 in-proc function app to .net 8 isolated function app due to the ending support of .net 6.
We are using the [Disable("FlagName")] to disable 60+ functions that using various triggers (queue trigger, service bus trigger, timer trigger etc), with just 1 appSetting "FlagName": "false". The use of AzureWebJobs.<FunctionName>.Disabled appsettings is not a good option, and it will cause the appsettings to be so dirty with 60+ disabled settings, because of the flag name with function name.
Please consider to support DisableAttribute back in isolated worker model asap. The migration experience from in-proc model to isolated worker model is very terrible.

If you need a basic solution, you could for example, wrap each Azure Function Job with appsettings checks, this means the function will execute regardless but the appsettings, will not let the primary code run. Its certainly not ideal but will solve the issue until someone actually starts solving these problems with a roadmap at MS.
Personally, due to the lack of response and answers from MS on various issues with Azure Functions over the last 2 years, i have moved most of our stuff away from using them, as luckily, we primarily only used it for Jobs rather than service bus stuff.

Thank you @wc-whiteheadd , letting the function app execute by checking the appsetting and not processing the message is not ideal, because it could cause the message go to dead-letter queue or poison queue. I'm adapting @Zoe1808 suggested workaround.

I also like the support for the disabled attribute. The app settings has a few downsides (next to others already mentioned):

if you want to disable many functions, it adds a lot of extra configuration
it is just a magic string, renaming the function name with disabled attribute works, but with the setting it might lead to accidently enabling it (if you forget to update the setting)

We use the disabled attribute for queue and blob triggers (locally we use storage queues and the blob trigger, in Azure we use service bus queues and event grid trigger). We just don't want to be dependent on Azure infrastructure locally, we use storage emulator for that.
Since we still want to update to .NET 8 we are now using app settings locally and in our release pipeline (Azure DevOps) we run this script before building:
- script: del /S /Q Local*.cs
  displayName: 'Remove local azure functions'
  workingDirectory: '$(Build.SourcesDirectory)/$(functionApp)'

This basically removes the local function triggers files, before building. This way they also can't be enabled by accident in production. This might be a solution, if you want functions always to be disabled in an environment.
Still I hope the [Disabled(setting)] attribute and as well [Singleton] attribute will be supported soon.


Fix Map for -develop

norfolkdrains-develop.herokuapp.com does not work because the map does not show.

Awesome, thanks, @stanzheng! Now comes the question: where do we use this? I don't actually see the key referenced in code anywhere.  The app/assets/javascripts/main.js.erb template doesn't actually use a map key, so is this something explicitly in Heroku?

@ryayak1460 check where the js for the google maps key is being loaded.
https://github.com/Code4HR/adopt-a-drain/blob/master/app/views/layouts/application.html.haml#L23
You just have to override the environment variable. Its a railism
Rails.application.secrets.google_maps_javascript_api_key

yup! probably just needs to be configured in the new environment or in the yaml file. Since these keys are semi-public because they're sent to the client it should be fine to include!

Who can update the value in Heroku? You, @stanzheng? @BretFisher? Or will we just update the value in the config file here in the repo?

ENVVAR's are set for each app in Heroku. Looks like GOOGLE_MAPS_JAVASCRIPT_API_KEY is set in both, but it's the same value. I updated the norfolkdrains-develop with the key above and the site seems to work for me. I'll close but reopen if it's not the true fix.


Exclude _bin from files copied to _public

Basically, treat files under _bin the same as those under _lib et cetera (i.e. tell the main loop to ignore them)... n.b. I did not a test for this because I wasn't sure of the best way to arrange the call to Generator.generateFolder. If you have suggestions, I'm happy to revise.

Thanks


Reduce number of figures in repo

Figures can be generated using simulation results
Create documentation for plotting figures

For some reason can't get .gitignore file to ignore .fig and .jpg

Removed all figures - required removing everything from index: https://stackoverflow.com/questions/19663093/apply-gitignore-on-an-existing-repository-already-tracking-large-number-of-file


[1.23] repo: Release v1.23.5

Commit Message:
Additional Description:
Risk Level:
Testing:
Docs Changes:
Release Notes:
Platform Specific Features:
[Optional Runtime guard:]
[Optional Fixes #Issue]
[Optional Fixes commit #PR or SHA]
[Optional Deprecated:]
[Optional API Considerations:]

this is the first release with the new automation, so should hopefully publish much quicker


Fix #715 - add team property to TeamInfoRequest

Add team property to TeamInfoRequest. This property is currently missing on the SDK, but is documented on the API docs.
Category (place an x in each of the [ ])

[ ] bolt (Bolt for Java)
[ ] bolt-{sub modules} (Bolt for Java - optional modules)
[x ] slack-api-client (Slack API Clients)
[ ] slack-api-model (Slack API Data Models)
[ ] slack-api-*-kotlin-extension (Kotlin Extensions for Slack API Clients)
[ ] slack-app-backend (The primitive layer of Bolt for Java)

Requirements
Please read the Contributing guidelines and Code of Conduct before creating this issue or pull request. By submitting, you are agreeing to the those rules.

 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.

@lfbrandao Thanks for your quick work here! Looks great to me 👍 I will merge this PR once we see the CI builds successfully pass.

wonderful, thanks @seratch!


Better support for python

Nice to have the following things:

On project import, a interpreter should be create via virtualenv where all declared dependencies should be installed
On project reimport all dependencies should be updated

Currently, I have to create a virtualenv and start bazel out of it which isn't really a good experience.

Any news or updates about downloading python dependencies and making them available inside the IDE?

Hi there! We're doing a clean up of old issues and will be closing this one. Please reopen if you’d like to discuss anything further. We’ll respond as soon as we have the bandwidth/resources to do so.


feat(postgres): extract user access

Is your feature request related to a problem? Please describe.
I need to have more metadata from postgres such as db users that have access to the table/dataset.
Describe the solution you'd like
Users access information on table metadata using postgres extractor

I think this query can be utilised here:
SELECT * FROM information_schema.role_table_grants;
Output:
grantor | grantee | table_catalog |    table_schema    |              table_name               | privilege_type | is_grantable | with_hierarchy
root    | root    | root          | pg_catalog         | pg_statistic                          | INSERT         | YES          | NO
root    | root    | root          | pg_catalog         | pg_statistic                          | SELECT         | YES          | YES
root    | root    | root          | pg_catalog         | pg_statistic                          | UPDATE         | YES          | NO
root    | root    | root          | pg_catalog         | pg_statistic                          | DELETE         | YES          | NO
root    | root    | root          | pg_catalog         | pg_statistic                          | TRUNCATE       | YES          | NO
root    | root    | root          | pg_catalog         | pg_statistic                          | REFERENCES     | YES          | NO
root    | root    | root          | pg_catalog         | pg_statistic                          | TRIGGER        | YES          | NO
root    | root    | root          | pg_catalog         | pg_type                               | INSERT         | YES          | NO
root    | root    | root          | pg_catalog         | pg_type                               | SELECT         | YES          | YES
root    | root    | root          | pg_catalog         | pg_type                               | UPDATE         | YES          | NO
root    | root    | root          | pg_catalog         | pg_type                               | DELETE         | YES          | NO
root    | root    | root          | pg_catalog         | pg_type                               | TRUNCATE       | YES          | NO
root    | root    | root          | pg_catalog         | pg_type                               | REFERENCES     | YES          | NO
root    | root    | root          | pg_catalog         | pg_type                               | TRIGGER        | YES          | NO
root    | root    | root          | pg_catalog         | pg_foreign_table                      | INSERT         | YES          | NO
should work?? because we have user, table_name and the privelage_type??
cc @StewartJingga @mabdh

What should be the metadata model with which we can pass it??
current I can provide the list of owners actually using Ownership *v1beta11.Ownership
but user access is very different right?? So I don’t think this is what we should use.
Is there a model where I can pass something like, username and privileges he has. For e.g.
test_user has SELECT,INSERT,UPDATE,DELETE and some other user user2 only has SELECT privelege.
wdyt?? @StewartJingga @ravisuhag @mabdh

@GrayFlash we can put those information inside Properties.Attributes fields inside Table model.
e.g.
&assetsv1beta1.Table{
	Properties: &facetsv1beta1.Properties{
		Attributes: utils.TryParseMapToProto(map[string]interface{}{
			"grants": []map[string]interface{}{
				{
					"user": "root",
					"privilege_types": []string{"SELECT", "INSERT"},
				},
				{
					"user": "myuser",
					"privilege_types": []string{"SELECT", "DELETE"},
				},
			},
		}),
	},
}

@StewartJingga should we also need to have an exclusion feature so user might be able to not getting the dbuser-privilege information of pg_catalog or others metadata tables.

@StewartJingga should we also need to have an exclusion feature so user might be able to not getting the dbuser-privilege information of pg_catalog or others metadata tables.

I think it depends on how we extract this information. @GrayFlash do you plan to fetch this information per table? or doing it in bulk initially?

@StewartJingga should we also need to have an exclusion feature so user might be able to not getting the dbuser-privilege information of pg_catalog or others metadata tables.

I think it depends on how we extract this information. @GrayFlash do you plan to fetch this information per table? or doing it in bulk initially?

I'm doing it per table so exclusion will not be an issue, as we have already excluded pg_catalog from extraction.


HIVE-26615: TestEncryptedHDFSCliDriver to use Tez

What changes were proposed in this pull request?

Why are the changes needed?

Does this PR introduce any user-facing change?

How was this patch tested?

the q out failures were not obvious enough to fix quickly, I'll get back to this one once I have the bandwidth, until this PR can remain closed


DCS World black display

ANY ISSUE FILED WITHOUT THE INFORMATION REQUIRED BELOW WILL BE CLOSED WITHOUT BEING LOOKED AT. NO EXCEPTIONS.
Describe the bug
DCS World (current version <IP_ADDRESS>731) started with its native OpenXR implementation (using --force_enable_VR  --force_OpenXR parameters) leads to black screens: Nothing can be seen on the desktop, not even a black filled window, and the HMD displays stay black. I can hear the game's sound, so it doesn't seem to crash, there are simply no visuals. Unchecking DCS.exe in the toolkit solves the problem, game is running fine again.
Environment

DCS World, current standalone version <IP_ADDRESS>731 (not the Steam version), tried both single and multi threaded versions of DCS, same results, OS: Windows 10, GPU: RTX 4090, Driver: Most current NVidia driver
OpenXR toolkit tested: 1.3.2 and 1.2.4
Varjo Aero HMD, Firmware and drivers are up to date

To Reproduce

Edit the shortcut used to start DCS and add the parameters "--force_enable_VR  --force_OpenXR" to force DCS to use its native OpenXR implementation. The whole entry in my case looks like this:
1.1 "C:\Program Files\Eagle Dynamics\DCS World\bin\DCS.exe" --force_enable_VR  --force_OpenXR
Start the game using the modified shortcut
See error (black screens, no visuals)

Expected behavior
The game should start and show its content, not only audio.
Screenshots
Black screens -> nothing to capture.

If you are on Varjo you cannot use OpenXR Toolkit unless you disable Quad Views mode.
This is explained on the website here (see the entry for DCS):
https://mbucchia.github.io/OpenXR-Toolkit/compat
Alternatively, you can look into https://github.com/mbucchia/Varjo-Foveated/wiki if you are only interested in foveated rendering.


Send test results to Cypress.io

Codecov Report

Merging #190 (a79f8b7) into develop (e96e20a) will not change coverage.
The diff coverage is 100.00%.

@@           Coverage Diff            @@
##           develop     #190   +/-   ##
========================================
  Coverage    98.09%   98.09%
========================================
  Files           85       85
  Lines          842      842
  Branches       167      167
========================================
  Hits           826      826
  Misses           9        9
  Partials         7        7

Impacted Files
Coverage Δ

src/components/UsaNavPrimary/UsaNavPrimary.vue
100.00% <100.00%> (ø)

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 e96e20a...a79f8b7. Read the comment docs.


UI updates

I could probably do some updates to the UI to match the styles from Steam. Also noticed that the mobile styles are different than the desktop styles so that could be something I should work on. I also noticed that the styles for the spoiler tag on the preview is different from spoiler tags used on Steam reviews

Hey there, thanks for letting me know and also volunteering 🙏🏾
It's entirely possible that the styling of the spoilers have changed since the tool was first released. I think at the time it was almost exactly a match, but I wouldn't be surprised if things have changed.


Fix #116: Move 'you' handling in invites to the client

@xPaw, does the client have a reference to the user's nick? If so, we could have the equality check in the template directly rather than passing that invitedYou in the event. If not, nevermind then.

Marking with priority label here: it's a regression compared to the latest release, v1.2.1, so let's not ship that in the next release.

:+1:

Will +1 and merge when @xPaw addresses (or not) my comment above :-)

It does not have a reference.
On Mon, 29 Feb 2016, 08:50 Jérémie Astori<EMAIL_ADDRESS>wrote:

Will +1 and merge when @xPaw https://github.com/xPaw addresses (or not)
my comment above :-)
—
Reply to this email directly or view it on GitHub
https://github.com/thelounge/lounge/pull/122#issuecomment-190068301.


Internal Server Error - Repeat Issue

Need to re-open issue #577 as per comment by  dmitriykovalev.
Repeat occurrence that I can't get past.
AIY Voice has been working fine for months. No changes on my side, but today when I run the python script that I have been using, I get:
"requests.exceptions.HTTPError: 500 Server Error: Internal Server Error for url: https://embeddedassistant.googleapis.com/v1alpha2/projects/voice-assistant-213123/deviceModels/voice-assistant-213123-voice-kit"
Please re-open & investigate.
Thanks, Carl.

@CarlP66 Is the issue still reproducible ?

No. The problem resolved itself as mysteriously as it occurred. I am pretty sure it was a transient issue at Google's end. I suspect I will see it again at some point......

@CarlP66 Sounds good, please reopen if it happens again.


[P in keyof T]: T[P] not accepting inferred base type via extends

TypeScript Version:  3.8.3

Search Terms:

[P in keyof T]?: T[P]
typescript generic extends in keyof
typescript generic extends T[P]
typescript mongo collection generic

Code
interface IModel {
	id: string;
}

type Query<T> = {
	[P in keyof T]?: T[P]
}

export class Base<T extends IModel> {
	public find(query: Query<T>): void {
		// Forward the query to database
		console.log(query);
	}

	public findOneById(id: string): void {
		this.find({ id });
	}
}

Expected behavior:
It's expected to allow to execute the find with the properties defined on IModel as base of any other model;
Actual behavior:
It shows an error:
Argument of type '{ id: string; }' is not assignable to parameter of type 'Query<T>'.ts(2345)

Playground Link:
https://typescript-play.js.org/#code/JYOwLgpgTgZghgYwgAgJIFkD2ATCAbZAbwCgBIYbALmQGcwpQBzAbmIF9jiwBPABxQCKAV2jcAPABUAfMgC8RMgG0ACslDIA1hG6YYyCQF0A-NQkqD7ThAAevTFDDIEeODRrIAQq4iTkNyCDY7hg4+DIkpLxCAEZ4wAjIMKDYABQAjiJQ3NTCopJSAJTUAG6YFAqkpAD0VcgAYvYA7nBQ2MhgABYoGaLtmMjYcGBw0d5kpAiYIDSYeBAAdHiYjOmZ3AWspBxkUbHxickA8iAQHtyoqRTUdAwgjEXIpeURpJ3ANPNJgSmEam1sGzIHA4QA
Related Issues:
Didn't find any related issue

Just for info, my type Query example is simplified version of what I'm trying to use form here

same issue

I guess this is related to #35858
interface IModel {
  id: string;
}

type Query<T> = {
  [P in keyof T]?: T[P]
}

export class Base<T extends IModel> {
  public findOneById(id: string): void {
    this.findT({ id });
//              ^^^^^
// Argument of type '{ id: string; }' is not assignable to parameter of type 'T'.
//  '{ id: string; }' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint 'IModel'.
  }

  public findT(query: T): void {
    console.log(query);
  }
}

This is unlikely to be fixed because TS cannot expand Query in compile time. If Query is replaced with other types, you will find it reasonable.  Playground
interface IModel {
  id: string;
}

type Query<T> = {
  [P in keyof T]: string
}

export class Base<T extends IModel> {
  public findOneById(id: string): void {
    // Error, T could be `anyType` & { id: string }
    this.findT({ id });
  }

  public findT(query: T): void {
    console.log(query);
  }
}

const b = new Base<{id: string, name: string}>();
b.findT({id: '1', name: '1'})

@Zzzen shouldn't TS evaluate T as IModel since every type passed needs to be extended/compatible with IModel?

Maybe this simplified example can help you? playground @rodrigok
interface IModel {
  id: string;
}

class Store<T extends IModel> {
  constructor(public data: T) {

  }

  setData(data: T) {
    this.data = data;
  }

  reset() {
    // Although `{ id: '1' }` is an element of `IModel`, `T` could be instantiated with `{ id: string, name: string }`, which `{ id: '1' }` is not compatible with

    //   Argument of type '{ id: string; }' is not assignable to parameter of type 'T'.
    // '{ id: string; }' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint 'IModel'.
    this.setData({ id: '1' })
  }
}

const storeWithName = new Store<{ id: string, name: string }>({ id: '1', name: 'foo' });
storeWithName.reset();
// Error
// Argument of type '{ id: string; }' is not assignable to parameter of type '{ id: string; name: string; }'.
//   Property 'name' is missing in type '{ id: string; }' but required in type '{ id: string; name: string; }'.
storeWithName.setData({ id: '1' })
storeWithName.setData({ id: '1', name: 'bar' })

@Zzzen thanks but it's not quite right since on query typing used by the find/findOne it users the partial of the type, so only id should be valid still.
Playground
interface IModel {
  id: string;
}

export class Base<T extends IModel> {
  public findOneById(id: string): void {
    this.findT({ id });
  }

  public findT(query: Partial<T>): void {
    console.log(query);
  }
}

// Should work
const b = new Base<{id: string, name: string}>();
b.findT({id: '1', name: '1'})
b.findT({id: '1'})
b.findOneById('1');

// Should not work and it doesn't
const c = new Base<{id: number, name: string}>();
c.findT({id: 1, name: '1'})
c.findT({id: 1})
c.findOneById(1);

@Zzzen thanks but it's not quite right since on query typing used by the find/findOne it users the partial of the type, so only id should be valid still.

you are right, but that's far beyond the ability of TypeScript.

I understand that this is tricky, but I think it's expected from the developer perspective since the extends creates a base definition for the types you can pass it would be expected to be able to use those fields, even if it's needed to pass any other modifier to allow it.

One problem with the original typing is that it doesn't account for subtypes with refined types for id. For example,
const obj = new Base<{ id: "foo" | "bar" }>();
obj.find("abc");

Note that { id: "foo" | "bar" } is a valid subtype of { id: string } according to TypeScript's general rules, and hence if findByOneId type-checked, you'd be passing an arbitrary string as though it were a "foo" | "bar".
In this particular case it's very innocuous, since find doesn't do anything with the id besides compare it to existing ones (so it would simply miss) - but the general typing machinery can't afford to look into the implementation to know whether such a thing is safe. Hence, it would open up even more unsoundness to allow this.
In short, {id: string} does not have to be a subtype of Query<T> or of T just because T is a subtype of {id: string}.
On the other hand, TypeScript rejects the following bit of code, which corrects for this issue. Hence I still think the situation can be improved, just not to support the original type annotations:
export class Base<T extends IModel> {
	public find(query: Query<T>): void {
		// Forward the query to database
		console.log(query);
	}

	public findOneById(id: T["id"]): void {
		this.find({ id });
                 //       ^^^^^^
                 // Argument of type '{ id: T["id"]; }'
                 //is not assignable to parameter of type 'Query<T>'.
	}
}

This does seem to be erroneous, since it's guaranteed that T has a field called "id" since T extends { id: _ }, and therefore { id } should be assignable to a Query<T>, which cannot have any required fields; and the only field we are passing is a T["id"] which surely is exactly the type that Query<T> has at key "id".

running into similar issues (also related to mongodb queries).
It seems this is only happening on generics.
see Playground Link

I'm not sure if my example is an instance of this same issue, but here's a very simple issue I encountered:

type Foo = {
    foo: string;
};

function stuff1<T extends Foo>(arg: string): Partial<T> {
    return {
        foo: arg,
    };
    // Type '{ foo: string; }' is not assignable to type 'Partial<T>'.
}

function stuff2(arg: string): Partial<Foo> {
    return {
        foo: arg,
    };
    // Works fine
}

https://www.typescriptlang.org/play?#code/FAFwngDgpgBA8gIwFYwLwwN7BjmAzAewIC4YBnEAJwEsA7AcwG5gBfZ4PAV1oGMRqCtGABMCAHgAqMKAA8QUWsLLxkAPgAUAQ0r1SFGgwCUpAArb+mgDaTVmbLkpQQnSkKy4P+IqW30ANPY4bKzAQA

@grumd your code has the same bug that I mentioned: T could be {foo: "abc" | "def"} and yet you could pass "xyz" as arg. The resulting value would not be a Partial<T> since "xyz" is not an "abc" | "def".
In your case, there's not much reason for you to just return a {foo: string}; the caller can decide to use it as a Partial<Whatever> if they feel inclined.

@Nathan-Fenner Oh, I guess I should have used arg: T['foo'] instead of string.

I was running in the same problem before i understood the concept of more restrictive subtypes.
So, i've tried to use the type from the generic itslef, T["foo"] in the above example but still no luck there. Should it be reported as a bug or am I getting something wrong:
type BaseType = {id: string};
function fun<M extends BaseType>(s: M["id"]): Partial<M> {
  return { id: s }; // Type '{ id: M["id"]; }' is not assignable to type 'Partial<M>'.
}

I submitted a fix with #42382, would really appreciate some feedback! 😄

I submitted a fix with #42382, would really appreciate some feedback! 😄


Readme enhancements

Readme enhancements
1. Add trigger tests methods to README
2. Enhance the origin description of the framework
FYI: Maybe https://github.com/Phaow/kcp-tests/blob/readme-enhancements/README.md will be better for review the .md file.

@xingxingxia @kasturinarra @wangke19 @duanwei33 @zxiao-redhat Could you please help to have a review when you get a chance? Thanks!

@Phaow some minor comments, else looks good to me. Also one question did you run all the smoke cases on the stable env at least once ?

@Phaow some minor comments, else looks good to me. Also one question did you run all the smoke cases on the stable env at least once ?

Yeah, I have run them on stable env many times, looks good.
./bin/kcp-tests run smoke
started: (0/1/5) "[area/transparent-multi-cluster] Author:pewang-Critical-[Smoke][BYO] Validate create, modifying, deleting a deployment from KCP gets synced to the pcluster [Suite:kcp/smoke/parallel/minimal]"

started: (0/2/5) "[area/apiexports] Author:pewang-Critical-[Smoke] Verify APIBinding working with personal workspace [Suite:kcp/smoke/parallel/minimal]"

started: (0/3/5) "[area/workspaces] Author:pewang-Medium-[Smoke] Multi levels workspaces lifecycle should work [Suite:kcp/smoke/parallel/minimal]"

passed: (34s) 2022-09-06T08:51:45 "[area/apiexports] Author:pewang-Critical-[Smoke] Verify APIBinding working with personal workspace [Suite:kcp/smoke/parallel/minimal]"

started: (0/4/5) "[area/common-version] Author:knarra-Medium-[Smoke] Checking kcp server version should display correctly [Suite:kcp/smoke/parallel/minimal]"

passed: (14.7s) 2022-09-06T08:52:00 "[area/common-version] Author:knarra-Medium-[Smoke] Checking kcp server version should display correctly [Suite:kcp/smoke/parallel/minimal]"

passed: (1m16s) 2022-09-06T08:52:27 "[area/workspaces] Author:pewang-Medium-[Smoke] Multi levels workspaces lifecycle should work [Suite:kcp/smoke/parallel/minimal]"

passed: (1m38s) 2022-09-06T08:52:49 "[area/transparent-multi-cluster] Author:pewang-Critical-[Smoke][BYO] Validate create, modifying, deleting a deployment from KCP gets synced to the pcluster [Suite:kcp/smoke/parallel/minimal]"

started: (0/5/5) "[area/workspaces] Author:zxiao-Medium-[Serial] I can create context for a specific workspace and use it [Suite:kcp/smoke/serial]"

passed: (17s) 2022-09-06T08:53:06 "[area/workspaces] Author:zxiao-Medium-[Serial] I can create context for a specific workspace and use it [Suite:kcp/smoke/serial]"

5 pass, 0 skip (1m55s)

Hi @kasturinarra , updated with enhanments, could you please help take a look again when you get a chance? Thanks!

@Phaow added few more comments, could you please help take a look when you are available ? thanks !!

@Phaow added few more comments, could you please help take a look when you are available ? thanks !!

Updated, could you please help take a look again when you get a chance? Thanks!

Done review from my side with minor comments.

Hi @xingxingxia @kasturinarra , updated with enhancements, could you please help take a look when you get a chance? Thanks!

LGTM except 2 minor comments inline.

LGTM except 2 minor comments inline.
Updated, PTAL again when you get a chance. Many thanks!

LGTM
/assign @kasturinarra

/lgtm


[Candidate 3v3 Medieval Era ZH v4] Outer Supply Piles have inconsistent building space

Observed behavior
Outer Supply Piles have inconsistent building space.
Expected behavior
Mirrored Supply Piles offer equal building opportunities.
Screenshots
Has no room

Has decent room

Has decent room

Has no room

Has decent room

Has tight room

fixed

GLA can now build supplies at all locations.
But China still cannot. The distances to the mountains are different.

should be fixed now, china supply able to be built everywhere on the supply crates between the players

Yes, looks good.


Implement arch

I would like to implement arch command which can be used to display machine architecture.

Completed implementation of 'arch' command.


./node_modules/.bin/catalog build throws

$ ./node_modules/.bin/catalog build
/myproject/node_modules/args/lib/utils.js:317
      throw err;
      ^

Error: spawn catalog-build ENOENT
    at exports._errnoException (util.js:1020:11)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:197:32)
    at onErrorNT (internal/child_process.js:376:16)
    at _combinedTickCallback (internal/process/next_tick.js:80:11)
    at process._tickCallback (internal/process/next_tick.js:104:9)
    at Module.runMain (module.js:606:11)
    at run (bootstrap_node.js:383:7)
    at startup (bootstrap_node.js:149:9)
    at bootstrap_node.js:496:3

This seems to be related to https://github.com/interactivethings/catalog/issues/343. Upgrading Catalog to a newer version should fix your problem.

I'm on recent version:
$  ./node_modules/.bin/catalog -v
3.5.2
$ ./node_modules/.bin/catalog start
/Users/safareli/myproject/node_modules/args/lib/utils.js:317
      throw err;
      ^

Error: spawn catalog-start ENOENT
    at exports._errnoException (util.js:1020:11)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:197:32)
    at onErrorNT (internal/child_process.js:376:16)
    at _combinedTickCallback (internal/process/next_tick.js:80:11)
    at process._tickCallback (internal/process/next_tick.js:104:9)
    at Module.runMain (module.js:606:11)
    at run (bootstrap_node.js:383:7)
    at startup (bootstrap_node.js:149:9)
    at bootstrap_node.js:496:3

While:
$ npm start

> @ start /Users/safareli/myproject
> catalog start

  Starting Catalog …

This seems to be a limitation of the args module which executes scripts from package.json instead of the subcommand files directly. When you run catalog start as an npm script, it works correctly because in the npm run context the scripts from package.json are available but otherwise not. I'm not sure what we can do to fix this other than document the issue somehow.
For reference: https://github.com/leo/args/issues/69, https://github.com/leo/args/issues/83

@safareli I'm closing this since there doesn't seem anything we can do about it at the moment. Feel free to ping me when the issue is resolved in args. Thanks!


docs: Update Gradle documentation for GRADLE_HOME path

The Gradle documentation previously stated that the Gradle home path should be "%GRADLE_HOME%/bin". This commit updates the documentation to use the correct path separator for Windows, which is "%GRADLE_HOME%\bin".
Fixes #25388
Context
This fix will help many first time gradle users to avoid windows gradle home errors due to wrong path.

@bot-gradle test and merge

I've triggered a build for you. Click here to see all failures if there's any.


Cleanup TransferFunction Input Sanitization

This started out to address #112 & #130, but I found a few other small edge cases.
To simplify unit testing I broke the input cleaning out to a separate function and added as many test cases as I could think of.
Deep copy
It performs a deep copy on args before anything else.
Test Code:
num = [[[1], [2]]]
den = [[[1,1], [2,1]]]
print(num)
print(den)
control.TransferFunction(num, den)
print(num)
print(den)

Before:
[[[1], [2]]]
[[[1, 1], [2, 1]]]
[[array([1]), array([2])]]
[[array([1, 1]), array([2, 1])]]

After:
[[[1], [2]]]
[[[1, 1], [2, 1]]]
[[[1], [2]]]
[[[1, 1], [2, 1]]]

Validate All Input Types:
The previous input validation would only check the first element if it was a valid input type. This means you could feed in extra bad values in other positions and it would accept it, only to fail later.
Test Code:
num = [[[1,"a"]]]
den = [[[2,1]]]
print(num)
print(den)
sys = control.TransferFunction(num, den)
print(num)
print(den)

Before:
It would accept the values (and mutate the inputs):
[[[1, 'a']]]
[[[2, 1]]]
[[array(['1', 'a'],
      dtype='<U21')]]
[[array([2, 1])]]

But fail when you tried to access the system:
   1013
   1014     for k in range(len(coeffs)):
-> 1015         coefstr = '%.4g' % abs(coeffs[k])
   1016         if coefstr[-4:] == '0000':
   1017             coefstr = coefstr[:-5]

TypeError: bad operand type for abs(): 'numpy.str_'

After
It fails immediately:
TypeError: The numerator and denominator inputs must be scalars or vectors (for
SISO), or lists of lists of vectors (for SISO or MIMO).

Added more valid types.
If you passed an numpy array as an input it would possibly fail depending on which architecture you were using it on. int resolves to int64 on 64-bit systems. It now accepts valid types of int, int8, int16, int32, int64, float, float16, float32, float64, float128. (If for some reason your transfer function parts were generated in another function).
Code:
import control
from numpy import array, int
num = array(1, dtype=int)
den = array([2, 1], dtype=int)
control.TransferFunction(num, den)

Before:
TypeError: The numerator and denominator inputs must be scalars or vectors (for
SISO), or lists of lists of vectors (for SISO or MIMO).

After:
    1
-------
2 s + 1

Added Tuple as valid collection for MIMO systems
It was easy enough to add and a valid ordered Python collection.
Given:
# Input 1 to Output 1
num11=[1]
den11=[2, 3]
# Input 1 to Output 2
num12=[4]
den12=[5, 6]
# Input 2 to Output 1
num21=[7]
den21=[8, 9]
# Input 2 to Output 2
num22=[10]
den22=[11, 12]

Previously this was the only valid MIMO input:
control.TransferFunction([[num11, num21],[num12, num22]], [[den11, den21],[den12, den22]])

Now all of these are also valid:
control.TransferFunction([(num11, num21),(num12, num22)], [(den11, den21),(den12, den22)])
control.TransferFunction(((num11, num21),(num12, num22)), ((den11, den21),(den12, den22)))
control.TransferFunction(([num11, num21],[num12, num22]), ([den11, den21],[den12, den22]))

Coverage decreased (-0.05%) to 77.274% when pulling 509ff8e849f27539016b15e41df6e8e61acd6a29 on jed-frey:InputSanitization into 5ab74cfbc15dd249ba5bc88a30f2957e05bb2984 on python-control:master.

*Created a branch and then merged the branch so that I can continue working. I wasn't aware that GitHub pull requests always tracked master, even after the request was created.

Coverage increased (+0.07%) to 77.4% when pulling d44489f1b0636a1010ad50f4a13a8723254f7b7b on jed-frey:InputSanitization into 5ab74cfbc15dd249ba5bc88a30f2957e05bb2984 on python-control:master.

FWIW, this fixes another bug:
(ctrl-py35) rory@rory-Inspiron-3521:~/Documents/python-control$ (cd ~/src/python-control && git checkout master)
Switched to branch 'master'
Your branch is up-to-date with 'upstream/master'.
(ctrl-py35) rory@rory-Inspiron-3521:~/Documents/python-control$ python -c "from control import tf; g=tf([[[1]]],[[[1,1]]]); print(g+g)"
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/home/rory/src/python-control/control/xferfcn.py", line 349, in __add__
    return TransferFunction(num, den, dt)
  File "/home/rory/src/python-control/control/xferfcn.py", line 163, in __init__
    MIMO).")
TypeError: The numerator and denominator inputs must be scalars or vectors (for
SISO), or lists of lists of vectors (for SISO or MIMO).
(ctrl-py35) rory@rory-Inspiron-3521:~/Documents/python-control$ (cd ~/src/python-control && git checkout InputSanitization)
Switched to branch 'InputSanitization'
Your branch is up-to-date with 'jed-frey/InputSanitization'.
(ctrl-py35) rory@rory-Inspiron-3521:~/Documents/python-control$ python -c "from control import tf; g=tf([[[1]]],[[[1,1]]]); print(g+g)"

   2 s + 2
-------------
s^2 + 2 s + 1

A few additional comments on this:

The same changes made here for xferfcn.py also need to be made in statesp.py and probably any other code that checks for data types int or float (need to add numpy types).

A quicker way to check against all of the numpy data types is to check against numpy.number.

Some related (and conflicting) changes are present in PR #170, though this PR goes beyond that in cleaning things up.

I'll try to do an integration of all of this in the coming days.

I submitted a pull request back to @jed-frey that addresses the issues above and also merges in the changes from PR #170, which are related, and the additional unit tests from PR #158 (also related).  Will wait a few days fro @jed-frey to integrate the changes, otherwise I'll submit a separate pull request with the combined changes.


[SPARK-42873][SQL] Define Spark SQL types as keywords

What changes were proposed in this pull request?
In the PR, I propose to define Spark SQL types as keywords.
Why are the changes needed?
The non-keywords types cause some inconveniences while analysing/transforming the lexer tree. For example, while forming the stable column aliases, see https://github.com/apache/spark/pull/40126.
Does this PR introduce any user-facing change?
No.
How was this patch tested?
By running the modified test suites:
$ build/sbt "test:testOnly *.ResolveAliasesSuite"
$ build/sbt "test:testOnly *.ParserUtilsSuite"

Highly likely, the GA continuous-integration/appveyor/pr is not related to my changes. I am going to merge this PR.

Merging to master. Thank you, @cloud-fan for review.


Sign in through Social Login LinkedIn throws 500 error

This is happening in local but also in production sometimes, it's harder to reproduce in production though

I need to go back to the site try to login again and then it works.

What error do you get in the server logs when this happens locally?
docker logs -f nhost-auth

What could also help is the full URL in your browser tab

After upgrading to the latest version of @nhost/nextjs and @nhost/react I no longer have this issue.

Hi @elitan  I though it had been fixed but I'm getting it again.
Here are the logs I'm getting on localhost:
{
  "level": 30,
  "time":<PHONE_NUMBER>400,
  "pid": 18,
  "hostname": "76c3cf7c8694",
  "req": {
    "id": 3,
    "method": "GET",
    "url": "/signin/provider/linkedin?redirectTo=http%3A%2F%2Flocalhost%3A3000%2F&locale=en",
    "query": {
      "redirectTo": "http://localhost:3000/",
      "locale": "en"
    },
    "params": {},
    "headers": {
      "host": "localhost:1337",
      "user-agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.54 Safari/537.36",
      "accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9",
      "accept-encoding": "gzip, deflate, br",
      "accept-language": "en-US,en;q=0.9,fr-CA;q=0.8,fr;q=0.7",
      "cookie": "chakra-ui-color-mode=dark; cc_cookie={\"level\":[\"necessary\"],\"revision\":0,\"data\":null,\"rfc_cookie\":false}; L=en-ca",
      "referer": "http://localhost:3000/",
      "sec-fetch-dest": "document",
      "sec-fetch-mode": "navigate",
      "sec-fetch-site": "same-site",
      "sec-fetch-user": "?1",
      "sec-gpc": "1",
      "upgrade-insecure-requests": "1",
      "x-forwarded-for": "::1"
    },
    "remoteAddress": "::ffff:<IP_ADDRESS>",
    "remotePort": 63906
  },
  "res": {
    "statusCode": 302,
    "headers": {
      "x-dns-prefetch-control": "off",
      "x-frame-options": "SAMEORIGIN",
      "strict-transport-security": "max-age=15552000; includeSubDomains",
      "x-download-options": "noopen",
      "x-content-type-options": "nosniff",
      "x-xss-protection": "1; mode=block",
      "access-control-allow-origin": "*",
      "surrogate-control": "no-store",
      "cache-control": "no-store, no-cache, must-revalidate, proxy-revalidate",
      "pragma": "no-cache",
      "expires": "0",
      "location": "https://www.linkedin.com/oauth/v2/authorization?state=7342e442-51eb-48a7-8a80-4a3d367c859d&response_type=code&redirect_uri=http%3A%2F%2Flocalhost%3A1337%2Fv1%2Fauth%2Fsignin%2Fprovider%2Flinkedin%2Fcallback&scope=r_emailaddress%20r_liteprofile&client_id=77yr0n3w084nwc",
      "content-length": "0"
    }
  },
  "responseTime": 24,
  "msg": "request completed"
}
{
  "level": 50,
  "time":<PHONE_NUMBER>464,
  "pid": 18,
  "hostname": "76c3cf7c8694",
  "msg": "Cannot read property 'redirectTo' of undefined"
}
{
  "level": 30,
  "time":<PHONE_NUMBER>464,
  "pid": 18,
  "hostname": "76c3cf7c8694",
  "req": {
    "id": 5,
    "method": "GET",
    "url": "/signin/provider/linkedin/callback?code=AQQbqtlt34SGvZY3jozuLSMcuCQwPlZubx9_9xZVM66kaLAvS5sVYLDwkZh8QrYuSQDDiWsyci2SDCDfRIJ144nLIKugN594vOFpOHeix15315JYYc5JbqJognnmHLxSFhIsUpMzBnH23yZQsN6Md6HM9ZxqGs28ECAnlpgkiamzYoHzY20mESM9RWJJAL2nHcSyhohxaJOYJDN_hs8&state=7342e442-51eb-48a7-8a80-4a3d367c859d",
    "query": {
      "code": "AQQbqtlt34SGvZY3jozuLSMcuCQwPlZubx9_9xZVM66kaLAvS5sVYLDwkZh8QrYuSQDDiWsyci2SDCDfRIJ144nLIKugN594vOFpOHeix15315JYYc5JbqJognnmHLxSFhIsUpMzBnH23yZQsN6Md6HM9ZxqGs28ECAnlpgkiamzYoHzY20mESM9RWJJAL2nHcSyhohxaJOYJDN_hs8",
      "state": "7342e442-51eb-48a7-8a80-4a3d367c859d"
    },
    "params": {},
    "headers": {
      "host": "localhost:1337",
      "user-agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.54 Safari/537.36",
      "accept": "text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9",
      "accept-encoding": "gzip, deflate, br",
      "accept-language": "en-US,en;q=0.9,fr-CA;q=0.8,fr;q=0.7",
      "cache-control": "max-age=0",
      "cookie": "chakra-ui-color-mode=dark; cc_cookie={\"level\":[\"necessary\"],\"revision\":0,\"data\":null,\"rfc_cookie\":false}; L=en-ca",
      "sec-fetch-dest": "document",
      "sec-fetch-mode": "navigate",
      "sec-fetch-site": "cross-site",
      "sec-fetch-user": "?1",
      "sec-gpc": "1",
      "upgrade-insecure-requests": "1",
      "x-forwarded-for": "::1"
    },
    "remoteAddress": "::ffff:<IP_ADDRESS>",
    "remotePort": 63926
  },
  "res": {
    "statusCode": 500,
    "headers": {
      "x-dns-prefetch-control": "off",
      "x-frame-options": "SAMEORIGIN",
      "strict-transport-security": "max-age=15552000; includeSubDomains",
      "x-download-options": "noopen",
      "x-content-type-options": "nosniff",
      "x-xss-protection": "1; mode=block",
      "access-control-allow-origin": "*",
      "surrogate-control": "no-store",
      "cache-control": "no-store, no-cache, must-revalidate, proxy-revalidate",
      "pragma": "no-cache",
      "expires": "0"
    }
  },
  "err": {
    "type": "Error",
    "message": "failed with status code 500",
    "stack": "Error: failed with status code 500\n    at ServerResponse.onResFinished (/app/node_modules/.pnpm/pino-http@5.8.0/node_modules/pino-http/logger.js:77:38)\n    at ServerResponse.emit (events.js:412:35)\n    at onFinish (_http_outgoing.js:792:10)\n    at afterWrite (internal/streams/writable.js:466:5)\n    at afterWriteTick (internal/streams/writable.js:453:10)\n    at processTicksAndRejections (internal/process/task_queues.js:81:21)"
  },
  "responseTime": 868,
  "msg": "request errored"
}

What I find particularly strange is this log
{
  "level": 50,
  "time":<PHONE_NUMBER>464,
  "pid": 18,
  "hostname": "76c3cf7c8694",
  "msg": "Cannot read property 'redirectTo' of undefined"
}

Because I'm sending this object to options
{
  "redirectTo": "/",
  "locale": "en"
}

What's even stranger is that when I go back to the site and I try to sign in again and this time it works fine. I don't know if it's because I'm already signed in in LinkedIn or not, I'm not asked the to sign in in LinkedIn anymore, but it just goes through and I get signed in.

This issue has been fixed.


refactor: reduce allocations from type assertion

Error looks to just be an ambiguity. I’ll update the TemplateExpression trait to be more generic

Pull Request Test Coverage Report for Build<PHONE_NUMBER>2
Details

3 of 4 (75.0%)  changed or added relevant lines in 2 files are covered.
2 unchanged lines in 1 file lost coverage.
Overall coverage decreased (-0.06%) to 95.163%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

src/TemplateExpression.jl
1
2
50.0%

Files with Coverage Reduction
New Missed Lines
%

src/InterfaceDynamicExpressions.jl
2
97.33%

Totals

Change from base Build<PHONE_NUMBER>0:
-0.06%

Covered Lines:
3128

Relevant Lines:
3287

💛  - Coveralls


Update image-builder.md

Remove dollar sign from lines 70, 72, 74 and 76.

@brmoreir : Thanks for your contribution! The author(s) have been notified to review your proposed change.

#pr-ready

#sign-off

@ritascosta: I'm sorry - only the author of this article, @kof-f, can sign off on your changes. But we do have an exception process - if you are on the Microsoft content or product team for this product area, you can ask the PR review team to review and merge it by sending mail to the techdocprs alias.


Interpolate overlay opacity

Copied from alessiocancian/react-native-side-menu/pull/7
Full credits of this PR to: @happymaskterriblefate
This PR allows the content overlay to fade in and out by interpolating the left Animated.Value to the opacity style prop on the overlay. It adds two new props to the component:

overlayOpacity: number with a default of 1
animateOverlayOpacity: bool with a default of true
and finally, it changes the rendering to always render the overlay, and adds a toggle on pointerEvents to determine if the overlay is interactive or if touches should simply pass through the overlay to main content.

Here's what it looks like before the PR:
https://user-images.githubusercontent.com/80355384/125297478-e1991f80-e2ec-11eb-8962-46f4b7aa7971.mov
with the code:
<SideMenu
  menu={
    <View style={{ flex: 1, backgroundColor: "white", justifyContent: "center", alignItems: "center" }}>
      <Text>This is the side menu!</Text>
    </View>
  }
  overlayColor="rgba(0, 0, 0, 0.7)"
>
  <View style={{ flex: 1, backgroundColor: "yellow", justifyContent: "center", alignItems: "center" }}>
    <Text>This is the main content!</Text>
  </View>
</SideMenu>

and here's what it looks like after the PR:
https://user-images.githubusercontent.com/80355384/125297549-ef4ea500-e2ec-11eb-8bdd-5b7c1f76f759.mov
with the code:
<SideMenu
  menu={
    <View style={{ flex: 1, backgroundColor: "white", justifyContent: "center", alignItems: "center" }}>
      <Text>This is the side menu!</Text>
    </View>
  }
  overlayColor="rgb(0, 0, 0)"
  overlayOpacity={0.7}
>
  <View style={{ flex: 1, backgroundColor: "yellow", justifyContent: "center", alignItems: "center" }}>
    <Text>This is the main content!</Text>
  </View>
</SideMenu>

If this PR and approach is welcome, I'll update the docs in the Readme as well.
Thanks for your time and consideration!

Hi Shobit, Is there a way to open the drawer on top of the content rather than pushing the content?

@kirannk-1306 - No, that is not supported by the original library.
As an alternative, if you're not looking for a pure JS implementation, you can use DrawerLayout
If you really need a pure JS implementation and are open to work on a PR, I can guide you on how to approach it.


Angular 7 karma test with importing external JS modules

I am testing a Angular 7 component which has importing JS modules like:
component.ts
import * as classA from '../../classA'; // Imported JS modules
export class component implements OnInit {
  public a = new classA(10); // Instantiate
  ...
}

classA.js
class classA {
  constructor (a) {
    this.max = a;
    ...
}

if (typeof module !== 'undefined' && typeof module.exports !== 'undefined') {
    module.exports = classA;
}

component.spec.ts
I am importing classA as what I did in component.ts.
    import * as classA from '../../classA';
Component.ts is working perfectly but when I am running ng test, this gives an error: TypeError: classA is not a constructor
I tried to include it in karma.conf.js like:
module.exports = function (config) {
  config.set({
    ...
    files: [
      "../app/classA.js"
    ]
  });
};

And in angular.json, I added
          "builder": "@angular-devkit/build-angular:karma",
          "options": {
            "main": "src/test.ts",
            "karmaConfig": "./karma.conf.js",
            "polyfills": "src/polyfills.ts",
            "tsConfig": "src/tsconfig.spec.json",
            "scripts": [
                  "../app/classA.js"
             ]

But still get same error. Anyone has any idea how to import JS modules in karma testing?

Please run karma with --log-level debug or the equivalent config file value.  Look through the log output carefully to see if your file is sent to the browser.
Try the new troubleshooting page https://github.com/karma-runner/karma/blob/2682bff15888cd88cc7e97be2e276cf1cb7f39be/docs/intro/05-troubleshooting.md


Remove final from exception class to fix #76

Hi @gregorwolf - Thank you for quick help on this issue. Regards, Krishna


FEATURE: Adding target for the group

Added the feature where analysts can target a specific CbR group. Minor fix with the help message for the minutes arg.

@keithmccammon @zacbrown

Thank you, @ruchirarya! We'll test this, and either provide feedback or merge.

Due to refactoring created new feature request to implement it with the new code base.
https://github.com/redcanaryco/cb-response-surveyor/issues/34


Fix build on Java 11

The main change to get working on Java 11 was to remove the dependency on spring-jdbc which requires Java 17. I managed to remove all the exclusions in the pom at the same time so I don't think they're needed. If a downstream project requires a specific version of one of the transitive libraries they can manage it themselves.

@adamdec0173 can you take a look? The exclusions made it harder to figure out where the Java 17 issue was as the error was pointing to commons-logging but it was actually due to spring. If we don't need all those exclusions I'd rather not have them.

As discussed via e-mail, let's go with removing all the exclusions for now, we can put them back if needed later.


[Enhancement] Add session variables: max_parallel_scan_instance_num (#19024) (#19233)

The parallelism number of scan cannot be adjusted manually. The parallelism number of automatically calculated is sometimes very high, taking up a lot of cpu、memory or io resources, but the performance improvement is not obvious. So we add a session variable to limit the maximum parallelism of scan. It's useful for restrict the resource of large scan query.

run starrocks_fe_unittest


Dealing with large files

I have a 2GB netcdf file. When I use this tool it eats up all the memory in my computer and then crashes. It would be nice if there were streaming support!

Thanks @evert  for the first issue , chunks support will be taken care of in next version

Awesome! I don't want to rush you, and I appreciate the work that goes into this, but when is soon? I have a deadline so I want to decide if i should wait or find another way to solve my problem. Again I appreciate the work so I hope this doesn't come across as demanding.

Hi @evert , running little busy , started working on your request. Can't assure the exact timing. Since you have a deadline , there are some suggestions that might give you some work around. Use xarray with dask for dividing your file to multiple smaller chunks of file  and then try to process them using directory conversion.
Example :- ```python
import xarray as xr
Open the input file
ds = xr.open_dataset('data.nc')
Get the size of the time dimension
ntime = ds.dims['time']
Split the file into 4 chunks
chunk_size = ntime // 4
for i in range(4):
start = i * chunk_size
end = start + chunk_size
chunk = ds.isel(time=slice(start, end))
chunk.to_netcdf(f'data_chunk_{i+1}.nc')

Hey thank you so much @anshuman61. I ended up finding a different workaround  by converting to GeoTIFF first. Thank you for taking the time to write this out for me though, it's super nice!


Chat Diorama

Hi @lalalune
I fixed the issue where the player's chat diorama would go out of frame when crouching or riding in a vehicle.
Please check it and give me feedback.

@ultrabot2022 please edit your comment to reference the Github issues this fixes and record a video of it working so QA knows what to look for.

@ultrabot2022 I tried it but the chat diorama and pfp, both are being viewed from the backside of the character. Thus back of the head is visible and not the face in both pfp and diorama. Can you fix this plz
https://user-images.githubusercontent.com/35926530/181254813-6eb4019f-f056-40a1-a6ae-85f53479218e.mp4

https://user-images.githubusercontent.com/80860637/181345857-e4f37334-b13e-4226-8d9d-8ee394a066f8.mp4
I fixed a chat diorama going out issue when a user sent a chat.
It seems the video that @alisaad673 provided has other issue, and I'll fix it soon.

https://user-images.githubusercontent.com/80860637/181352926-27da133c-e1e6-4317-b166-238226014477.mp4

This looks good but probably should run by @avaer to make sure the framing is what he had in mind

@ultrabot2022 looks good but left some comments, we should try to avoid making any new allocations

@ultrabot2022
The pfp is still being shown from the backside. Also you need to rebase it over to master i guess as its on an older version and a few prs were reverted from that version. Also the street scene is empty in your branch.

https://user-images.githubusercontent.com/80860637/181662471-c789cd84-8069-4f34-a82f-f3c13ef4b06e.mp4
@alisaad673. This function is working well on my side. Please check again.

https://user-images.githubusercontent.com/80860637/181662471-c789cd84-8069-4f34-a82f-f3c13ef4b06e.mp4
@alisaad673. This function is working well on my side. Please check again.

https://user-images.githubusercontent.com/80860637/181662471-c789cd84-8069-4f34-a82f-f3c13ef4b06e.mp4
@alisaad673. This function is working well on my side. Please check again.

https://user-images.githubusercontent.com/80860637/181662471-c789cd84-8069-4f34-a82f-f3c13ef4b06e.mp4
@alisaad673. This function is working well on my side. Please check again.


Feature request: Add 'Copy as values' menu to context menu

Currently, We can get the original formula rather than values when copy and paste the area of the selected sheet.
So I wanna new feature like below.

I think this feature will help many people.

You can change the behavior by using copyCompatibility: true in the innitalization.

Oh, I got it. Thanks! :)


Should KeywordRecognitionModel be singleton or transient

Hi,
I'm trying to run this SDK on a server app where different audio streaming sessions may have the Keywords that the app needs to recognize.
I have created a model for Keyword Recognition from speech studio and I'm seeing huge performance problems when I run close to ~10 concurrent sessions.
Right now I'm using the model as a singleton, so all sessions share the same model instance (which works fine for 2-5 sessions).
What is the best practice regarding this? should I create a new KeywordRecognitionModel instance for each session?
A close approximation of the code looks like below:
// static/singleton model instance
static KeywordRecognitionModel model = KeywordRecognitionModel.FromFile($"{modelPath}");

// all below instances are 1 per session
var callback = new CustomPullStreamReaderCallback();
PullAudioInputStream pullStream = AudioInputStream.CreatePullStream(callback);
var audioConfig = AudioConfig.FromStreamInput(pullStream);
var kw = new KeywordRecognizer(audioConfig);

var result = await context.Recognizer.RecognizeOnceAsync(model);

Speech SDK version used: 1.16.0
Application Env: Linux container (azure AKS)
Technology: .Net 5 (C#)

@ShrivastavaAkash Thanks for the report. We are checking what is the main reason for the performance issue and let you know what could be best approach here. I believe it is just due to several instances of KeywordRecognizer running at the same time. I would believe also that using singleton model or several model (e.g. separate KWS model per instance) does not make a difference to performance.

After checking this, it is known that current KWS model is CPU expensive and that is the reason for the CPU load issue you have with several instances (over 5). We have work ongoing to improve the model in future to consume less CPU and memory. Closing the item.


remove redundant parsing in syntax macro

This seems to save a substantial amount of time.

After:
total-time:            2642 ms
    rust-time:             1975 ms
        init-and-types:        1087 ms
        lifetime-time:          887 ms
        compile-time:             0 ms
...

Nicely done!

Awesome.


cli: Provide option to redeploy programs per test suite

anchor test should allow one to start from a fresh state for individual test suites.

solved by https://github.com/project-serum/anchor/pull/1681


Engine Usage Reactors

Creating 6 new Reactors to return Metrics for Engine Usage

AdminGetAllEngineUsageReactor
GetAllEngineUsageReactor
AdminGetEngineUsagePerProjectReactor
GetEngineUsagePerProjectReactor
AdminGetEngineUsagePerUserReactor
GetEngineUsagePerUserReactor

Reactors take in EngineId, limit, offset, DateFilter
pls feel free to tell me to rename these reactors

Let's do it as START_DATE and END_DATE for defining a date range instead of just a single > DATE value


Build pipeline cb

 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.:x: Charletta sign nowYou have signed the CLA already but the status is still pending? Let us recheck it.


AssertionError: Too many number of crops

I changed the size of the input image, but this error will appear during the training process. Does anyone know the reason?

We don't have any idea unless you upload your error message. You should specify where the error comes from.
Please show your whole error message. It should read something.


[PE-D][Tester A] Incorrect association in the Model UML diagram

From this image it tells me that a Person will be composed of 0 or more Issues. Thus this means that I can add issues even without the person having a Car. However when I add a new person with just issues it tells me that it must have a car in order for it to have issues.
I also noticed that you mentioned in in the developer guide that if the person has a car it can have issues. Therefore it should be that the car object is associated to 0 or more issues not the person itself. Thus the diagram is incorrect.

Labels: type.DocumentationBug severity.High
original: Nicholas-Cheng-De-Fei/ped#14

Good spot, but severity exegerated


debug sql queries works with nil ar logger

Sometimes in the console you need to turn active record logging off.
This no longer blows up when you set ActiveRecord::Base.logger = nil
(There is probably a better way but...)

Maybe you forgot about toggle_console_sql_logging or I'm misunderstanding.
irb(main):003:0> Vm.first
PostgreSQLAdapter#log_after_checkout, connection_pool: size: 5, connections: 1, in use: 1, waiting_in_queue: 0
  Vm Load (10.0ms)  SELECT "vms".* FROM "vms" WHERE "vms"."type" IN ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11, $12, $13, $14, $15, $16, $17, $18) AND "vms"."template" = $19 ORDER BY "vms"."id" ASC LIMIT $20  [["type", "Vm"], ["type", "VmServer"], ["type", "ManageIQ::Providers::InfraManager::Vm"], ["type", "ManageIQ::Providers::Kubevirt::InfraManager::Vm"], ["type", "ManageIQ::Providers::Redhat::InfraManager::Vm"], ["type", "ManageIQ::Providers::Microsoft::InfraManager::Vm"], ["type", "ManageIQ::Providers::Vmware::InfraManager::Vm"], ["type", "ManageIQ::Providers::CloudManager::Vm"], ["type", "ManageIQ::Providers::Amazon::CloudManager::Vm"], ["type", "ManageIQ::Providers::Azure::CloudManager::Vm"], ["type", "ManageIQ::Providers::AzureStack::CloudManager::Vm"], ["type", "ManageIQ::Providers::Google::CloudManager::Vm"], ["type", "ManageIQ::Providers::IbmCloud::VPC::CloudManager::Vm"], ["type", "ManageIQ::Providers::IbmCloud::PowerVirtualServers::CloudManager::Vm"], ["type", "ManageIQ::Providers::Openstack::CloudManager::Vm"], ["type", "ManageIQ::Providers::IbmPowerVc::CloudManager::Vm"], ["type", "ManageIQ::Providers::OracleCloud::CloudManager::Vm"], ["type", "ManageIQ::Providers::Vmware::CloudManager::Vm"], ["template", false], ["LIMIT", 1]]
  Vm Inst Including Associations (0.1ms - 0rows)
=> nil
irb(main):004:0> Host.first
  Host Load (6.7ms)  SELECT "hosts".* FROM "hosts" ORDER BY "hosts"."id" ASC LIMIT $1  [["LIMIT", 1]]
  Host Inst Including Associations (0.0ms - 0rows)
=> nil
irb(main):005:0> toggle_console_sql_logging
=> 1
irb(main):006:0> ExtManagementSystem.first
=> #<ManageIQ::Providers::EmbeddedAnsible::AutomationManager id: 1, name: "Embedded Ansible", created_on: "2021-05-12 19:57:42", updated_on: "2021-05-20 22:10:44", guid: "3b668744-2553-46ee-a798-266a947395f0", zone_id: 2, type: "ManageIQ::Providers::EmbeddedAnsible::AutomationMa...", api_version: nil, uid_ems: nil, host_default_vnc_port_start: nil, host_default_vnc_port_end: nil, provider_region: nil, last_refresh_error: nil, last_refresh_date: nil, provider_id: 1, realm: nil, tenant_id: 1, project: nil, parent_ems_id: nil, subscription: nil, last_metrics_error: nil, last_metrics_update_date: nil, last_metrics_success_date: nil, tenant_mapping_enabled: nil, enabled: true, options: nil, zone_before_pause_id: nil, last_inventory_date: nil, capabilities: {}>
irb(main):007:0>

Is setting the logger to nil a debug thing, or in a real code path?  Add opposed to nil can you set it to Logger.new(nil)?

I can do Logger.new(nil)
but the whole code base works with the nil except for this added debugging statement we decided to add


extra checks have been added to the shared pipeline to ensure change authors are project collaborators before deploying snapshot PR

NOTE: not using semantic release comments as this is a CI change, no release required

@rawlingsj fabric8/fabric8-ui:SNAPSHOT-PR-2196-1 is deployed and available for testing at https://fabric8-ui-fabric8-ui-pr-2196-fabric8-planner.badger.fabric8.io

Can this be merged please?

@rawlingsj fabric8/fabric8-ui:SNAPSHOT-PR-2196-3 is deployed and available for testing at https://fabric8-ui-fabric8-ui-pr-2196-fabric8-planner.badger.fabric8.io


Sometimes playback is automatically paused

Playback is getting paused automatically without any interruptions or any actions. The network connectivity is good and the playback has to be manually resumed by hitting play again.
Observed this happening with recent updates.

Hi there,
I haven't experienced this bug although I'm not yet using latest release in production. Does this happen randomly or is there a way to reproduce? Do you play livetreams?
If you have more information you care to share, let me know :)

Thanks for your response. I tried to reproduce this, but was unable to. I'm using remote MP3 Urls for playing this.
I know that using below method is not correct, but I'm trying to test the issue. So, I used a youtube audio url and it just throws error saying The operation cannot be completed. But, the same thing works fine when I instantiate AVPlayer..

This is interesting although unrelated to this issue. Would you mind creating a separated one? I want to look into it :)

Will do. I will try to use a youtube URL and replicate the issue and document those. Thanks.

What kind of Youtube's URL do you use? I just tried to get an URL to a YouTube's mp4 (containing video) and it worked out of the box.

i'm using a mp4 audio link. I don't have access from work, but the process I did for testing is,
I took a youtube song url, then went to www.clipconverter.cc and then used firebug or http packet tool for sniffing network traffic.
then when you enter youtube url in that site and hit enter or something it sends request to grab youtube urls. You can see the JSON response and it will have urls in it.
you can take any URL and it will have 2 links in it concatenated together by #audio= something like that.
the url after #audio= is the audio url for that resolution of video :)

if you want to test that url, you can paste that url in safari and it will play automatically if the song link is correct. Safari kicks off AVPlayer and if that can be played in safari, it should work in this library too.. technically :)

That is what I did and it worked

Also, it worked with the video URL.

that's weird.. let me try tonight and i will get back to you with the video that it didn't work. May be its only related to the videos i'm using :)

Here is a song I tried.. Just a random pick :)
https://www.youtube.com/watch?v=8B29SZvMi3E
Here is the audio URL that i received. This might expire by the time you check.
https://r8---sn-4g57knkl.googlevideo.com/videoplayback?id=o-AIvdELTMN9fvcZsV8e-a7CSDfl_piJZ_izysVXrkqIdF&pl=23&signature=6DE6D58CE64B3E93A67F6A9D5AADAE90B6B45815.4AB0EBA7EB63936A9685391FC27C2C8E157499C4&ipbits=0&key=cms1&ip=<IP_ADDRESS>&gir=yes&fexp=9406993,9416126,9420452,9422596,9423661,9423662,9425397,9428243,9428605,9429122,9429131,9429237,9430941,9431117&dur=263.058&sparams=clen,dur,expire,gir,id,initcwndbps,ip,ipbits,itag,keepalive,lmt,mime,mm,mn,ms,mv,nh,pl,requiressl,source,upn&requiressl=yes&expire=1457679383&mime=audio/mp4&itag=140&sver=3&clen=4224031&source=youtube&upn=1EHRhk_Nwf0&keepalive=yes&lmt=1411540153995309&ratebypass=yes&redirect_counter=1&req_id=aa7d376bf6f3a3ee&cms_redirect=yes&mm=34&mn=sn-4g57knkl&ms=ltu&mt=1457657860&mv=m&nh=IgpwcjAyLmZyYTE1KgkxMjcuMC4wLjE#audiosize=4224031
Error I got:
didChangeStateFrom error : Optional(Error Domain=AVFoundationErrorDomain Code=-11800 "The operation could not be completed" UserInfo={NSUnderlyingError=0x7fa4f35db4c0 {Error Domain=NSOSStatusErrorDomain Code=-12936 "(null)"}, NSLocalizedFailureReason=An unknown error occurred (-12936), NSLocalizedDescription=The operation could not be completed})

I did lot of research and found something messed up with my current setup. I created new Xcode project and tried above urls and they worked fine. I reimported my code and processes to this version and so far it seems good. Something might have messed up with other setup. I will do more testing and report if there are any issues.
I think you can close this for now :) thanks for your help and sorry for the trouble .. you rock

Let me know if I can help.
I'm going to close this issue for now, since I haven't been able to reproduce at all. If you could come back in this thread if you have more information/it happens again, I would be grateful!
Thanks.


Bare staple value not handled in finishings-supported

I have encountered a driverless printer that includes staple in the finishings-supported attribute, but doesn't have any of the other staple-XXX values.  The PPD generated by cupsd doesn't contain any of the *StapleLocation or *cupsIPPFinishings keywords that normally get generated for other printers.
Taking a look at the section starting at cups/ppd-cache.c:4517, it seems like this is supposed to work by mapping through the SingleAuto keyword.  But the two checks on lines 4553 and 4600 only match values that start with staple-, so the bare staple value never gets handled.  Locally patching in a check for strcmp("staple") makes things behave the way I would expect and also looks similar to the checks done for other finishings later in the same file, but I'm not sure if I might be missing something here.
Is the bare staple value supposed to work when the other staple-XXX values aren't present?  I couldn't find anything in the IPP Finishings doc saying it shouldn't, but finishings has been covered in enough different places that I don't have confidence I read everything relevant.  If it is supposed to work, do you want me to send a quick PR to add the missing value to the checks?
The same issue might apply to a bare bind value based on the similar pattern in the same checks.
I've attached an ippserver config captured from this printer in case you want to look through the whole set of attributes.
HL-L6415DW.conf.txt

Confirmed, will also make sure the base "punch" and "fold" values are covered as well.

Just wanted to double-check on this.  Would it be helpful for me to send a PR?

@yetamrra PRs are always welcome!

Sure thing.  I sent #1094 with a proposed fix.

Sorry, I forgot to post a follow-up here.  We've cherry picked the fix into the 2.4 branch on ChromeOS and confirmed that it works as expected with the original printer.


Add support for SALUS SP600 socket

Device description
Salus SP600 as described here - https://www.zigbee2mqtt.io/devices/SP600.html
MQTT message with device information
PUT here the device data you receive when publish message with topic
zigbee2mqtt/bridge/config/devices, as example
{"ieeeAddr":"0x001e5e0902145f59","type":"Router","networkAddress":59137,"model":"SP600","friendly_name":"Tumble_Dryer","manufacturerID":4216,"manufacturerName":"Computime","powerSource":"Mains (single phase)","modelID":"SP600","hardwareVersion":2,"dateCode":"20160217","lastSeen":1585920798280}

MQTT messages from device
Put here examples of MQTT messages with different states you've received from device, as example
info  2020-04-03 14:47:32: MQTT publish: topic 'zigbee2mqtt/Tumble_Dryer', payload '{"energy":0.13,"linkquality":23,"state":"ON","power":285.5}'

MQTT state change commands
See here - https://www.zigbee2mqtt.io/devices/SP600.html

I've got this working for now by adding the following to the top-level init.py:
 'SP600': OnOffKwhAdapter,

Done, could you please update plugin and check

productive day :-)

Perfect - thank you!


Can set Boriel ZX Basic optimization level to 4

In VSCode Settings can be set optimization level to 4:
"Value must be less than or equal to 3."
Boriel ZX Basic has 4 optimization levels.
Thanks for your work!

I've fixed this issue. It will be released in v0.7.0. By then, you can use this private build:
kliveide-vsext-0.6.0.zip
(Please, rename the .zip file to .vsix so that you can install it in VS Code)

Released in v0.7.0


Use rsync instead of synchronize here.

This was affecting static install in Chris's cluster.

looks good!

Ok


Improve performance of casting StringView/BinaryView to DictionaryArray

Which issue does this PR close?

Part of #5861 . This pr should only be reviewed/merged after #5871 is merged.
Rationale for this change
Cast view types to dictionary arrays, the opposite of https://github.com/apache/arrow-rs/pull/5871
Note that casting was handled by pack_byte_to_dictionary:
https://github.com/XiangpengHao/arrow-rs/blob/dict-to-view/arrow-cast/src/cast/dictionary.rs#L307
But it takes two steps: Utf8View -> Utf8 -> Dictionary, which causes two copies.
This PR only do one copy (directly from Utf8View -> Dictionary<>)

What changes are included in this PR?

Are there any user-facing changes?

I took the liberty of merging this PR up from main. Running performance benchmarks on it now

Does this PR close #5861 I wonder 🤔

I guess it should. Are there any remaining items?

I guess it should. Are there any remaining items?

Not that I know of

🚀


Insert into temp table with fast_executemany + executemany loses fraction of seconds

Environment
To diagnose, we usually need to know the following, including version numbers.  On Windows, be
sure to specify 32-bit Python or 64-bit:

Python: 3.9.16
pyodbc: 4.0.34
OS: CentOS Linux release 7.7.1908
DB: SQL Server 15.0.2000.5
driver: ODBC Driver 17 for SQL Server (<IP_ADDRESS>)

Issue
import pyodbc, datetime, struct
def datetime_as_string(raw_bytes):
tup = struct.unpack("<2l", raw_bytes)
days_since_1900 = tup[0]
partial_day = round(tup[1] / 300.0, 3)
return datetime.datetime(1900, 1, 1) + datetime.timedelta(days=days_since_1900) + datetime.timedelta(seconds=partial_day)
cnx = pyodbc.connect('....')
cnx.add_output_converter(pyodbc.SQL_TYPE_TIMESTAMP, datetime_as_string)
cur = cnx.cursor()
cur.fast_executemany = True
cur.execute("CREATE TABLE #tmptest (dt DATETIME)")
cur.execute("INSERT INTO #tmptest VALUES('2023-05-17 15:00:55.23')")
cur.executemany('INSERT INTO #tmptest VALUES(?)', [[datetime.datetime(2023,5,17,15,0,55,230000)]])
cur.fast_executemany = False
cur.executemany('INSERT INTO #tmptest VALUES(?)', [[datetime.datetime(2023,5,17,15,0,55,230000)]])
print(cur.execute('SELECT * FROM #tmptest').fetchall())
Output:
[(datetime.datetime(2023, 5, 17, 15, 0, 55, 230000),), (datetime.datetime(2023, 5, 17, 15, 0, 55),), (datetime.datetime(2023, 5, 17, 15, 0, 55, 230000),)]
fast_executemany + executemany loses fraction of seconds

Does it only happen with a temp table, and not persistent tables? If so, try enabling the UseFMTONLY option. Otherwise, post an ODBC trace so we can inspect it to see what's going on.

@v-chojas UseFMTONLY fixes the issue! thank you!


[utils] Add get_realpath function

Since "realpath" function is not available in the Windows operating system, "get_realpath" function has been added and replaced so that it can be used in the Windows operating system.

Add get_realpath function to utils.

Self evaluation:

Build test: [x]Passed []Failed []Skipped
Run test: [x]Passed []Failed []Skipped

Signed-off-by: Seungbaek Hong<EMAIL_ADDRESS>

:memo: TAOS-CI Version: 1.5.20200925. Thank you for submitting PR #2050. Please a submit 1commit/1PR (one commit per one PR) policy to get comments quickly from reviewers. Your PR must pass all verificiation processes of cibot before starting a review process from reviewers. If you are new member to join this project, please read manuals in documentation folder and wiki page. In order to monitor a progress status of your PR in more detail, visit http://ci.nnstreamer.ai/.

Plz, Check the CI.

LGTM

:octocat: cibot: @baek2sm, A builder checker could not be completed because one of the checkers is not completed. In order to find out a reason, please go to http://ci.nnstreamer.ai/nntrainer/ci/repo-workers/pr-checker/2050-202211301509200.16678190231323-49d4ddd53fe185783fbff0263d95683654db6764/.


locality zone name is looked up often when running with --use-fake-symbol-table 0

When disabling the fake symbol table, I see the following:
$ while :; do curl -s 0:9901/stats/recentlookups ; echo ; sleep 1 ; done
....
   36778 zone_name_X
   36913 zone_name_Y
   36979 zone_name_Z
...

Note: those numbers aren't going up that fast, it's a few thousand every couple of seconds. Also, it doesn't show up in CPU/mem perf profiling. But it might still be good to clean it up.
What we probably want is to avoid creating a new Stats::StatNameManagedStorage every time a HostDescription instance is constructed:
https://github.com/envoyproxy/envoy/blob/master/source/common/upstream/upstream_impl.cc#L257
We could have a std::unordered_map<std::string, StatName> in PriorityStateManager, and the just pass a reference to the StatName every time a HostImpl is created here:
https://github.com/envoyproxy/envoy/blob/master/source/common/upstream/upstream_impl.cc#L1210
Again, I don't think this is a blocker for changing the default value on the --use-fake-symbol-table flag.
cc: @jmarantz

on it

This turns out to be a little messier than anticipated. @rgs1 suggested above we could store a map in the PriorityStateManager, but is one of those always available when we make HostDescriptionImpls? I started to make that change but found the fanin of contexts growing. I'll take a look more later with fresh start.
Also, I think as @rgs1 observed this is not really mission-critical because these don't get created in the request flow, IIUC.

@mattklein123 could use your advice on which of the many places (dozens?) HostImpl is instantiated this is most likely to be. Ideally we could capture a StatNameSet with a structure we populate when we learn about new hosts (e.g. on an EDS update), and then never reference the hostname again by string.
But because there are so many instances where Hostimpl is instantiated, and I'm not sure they all are triggered by xDS, I might lull myself into thinking I've fixed this problem when I might only have captured the names one level in the call-stack higher but no less frequently.
Thanks for your help!

I would assume it's during the EDS update process? cc @snowp

I would imagine the main flow is through EDS updates, though new HostImpl would also be created during other discovery flows (e.g. STRICT_DNS), in which case it would happen during CDS update

I'm considering making the zone-name a dynamic segment so we just avoid this issue and the huge refactor to keep zone->StatName maps available for all callers.
Switching to a dynamic segment is (for the impl) one-word change:
diff --git a/source/common/upstream/upstream_impl.h b/source/common/upstream/upstream_impl.h
index 372716d078..57fca9a2b6 100644
--- a/source/common/upstream/upstream_impl.h
+++ b/source/common/upstream/upstream_impl.h
@@ -149,7 +149,7 @@ protected:
   mutable absl::Mutex metadata_mutex_;
   MetadataConstSharedPtr metadata_ ABSL_GUARDED_BY(metadata_mutex_);
   const envoy::config::core::v3::Locality locality_;
-  Stats::StatNameManagedStorage locality_zone_stat_name_;
+  Stats::StatNameDynamcStorage locality_zone_stat_name_;
   mutable HostStats stats_;
   Outlier::DetectorHostMonitorPtr outlier_detector_;
   HealthCheckHostMonitorPtr health_checker_;

A future refactor could make it feasible to track a symbolic StatName for each zone through the call-sites but I think this makes sense for now. SG?

I like it -- I don't think introducing the zone --> StatName maps is worth the complexity at this point. If switching to a dynamic segment makes the lookups go away (at the expense of some allocations maybe -- not that it matters, not a hot path anyway), I think we should do it.