UnmaskFragment type never

Hello, I come from https://github.com/dotansimha/graphql-code-generator/pull/9708#issuecomment-2305949809, first of all many thanks :)
When using it like so:
const FolderPathFragment = graphql(`
    fragment FolderPathFragment on Folder {
      name
      site {
        sitename
      }
    }
  `);
  type UnmaskedFolderPath = UnmaskFragment<typeof FolderPathFragment>;

I get type UnmaskedFolderPath = never, not sure what could be the cause.
this is my codegen.ts just in case:
import type { CodegenConfig } from "@graphql-codegen/cli";
import dotenv from "dotenv";

const config: CodegenConfig = {
 schema: process.env.GRAPHQL_ENDPOINT,
 documents: ["db/**/*.tsx", "db/**/*.ts"],
 ignoreNoDocuments: true,
 generates: {
   "./graphql/": {
     preset: "client",
     presetConfig: {
       fragmentMasking: { unmaskFunctionName: "getFragmentData" },
     },
     config: {
       documentMode: "string",
     },
   },
   "./graphql/types.ts": {
     plugins: ["typescript", "typescript-operations"],
     config: {
       enumsAsTypes: false,
       skipTypename: true,
     },
   },
   "./schema.graphql": {
     plugins: ["schema-ast"],
     config: {
       includeDirectives: true,
     },
   },
 },
};

export default config;

Fixed it
type FolderPathFragmentType = FragmentType<typeof FolderPathFragment>;
type UnmaskedFolderPathBase = UnmaskFragment<FolderPathFragmentType>;

This worked, however, it wasn't obvious reading the https://github.com/tnyo43/graphql-code-generator-unmask-fragment/blob/main/README.md, perhaps documenting it a bit better would help, what do you think @tnyo43?

@adriangalilea Thanks for the comment and investigation!
That is correct. I'll fix it.


s25rttr: init at 0.9.5

Description of changes
RTTR is a settler 2 clone, which re-implements the game to bring classical settler 2 to modern OS and also adds a lot of (optional) things to the game, like multiplayer and other game changes, while keeping "old" game experience in mind.
The game itself requires the user to own a original copy of the game (to be more specific Settler 2 Gold Edition), as its using the originals games assets.
The files have to be placed at a specific folder by the enduser.
The game will exit with a console message if the game files are not placed at the expected directory.
Upstream places the game files in the application directory of the game itself, which is not possible for nix users as the store is read only.
Preloading the files to the store and depending on them should result in a variant which will never be build by hydra, which is a non-optimal user experience.
So in a discussion with NoobZ and me on the unofficial nixos discord and another discussion between a person from upstream (s25rttr) and me, i came to the solution presented here.
The game directory points to /var/lib/s25rttr/S2. That place may be not optimal, but i dont see another predictable folder where to look for the files, as long as its not definable on runtime.
The game does not need S2 proprietary files on compile time, they are just loaded on game start.
So building it with hydra should be fine.
The game itself builds fine that way and is also in a usable state. I have tested some minutes in single player and joined a multiplayer session opened with upstream builds (started local with steam-run).
Every feedback is welcome, if someone has a better idea for the game-data solution, i would be happy to test it out.
The package just needs SDL2 withStatic=true due https://github.com/NixOS/nixpkgs/pull/149601 not being merged, and the CMake plugin searches for libSDL2main.a to read out the versions.

Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[x] Tested basic functionality of all binary files (usually in ./result/bin/)
22.05 Release Notes (or backporting 21.11 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module
[ ] (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes

[x] Fits CONTRIBUTING.md.

/marvin opt-in
/status needs_reviewer

i found some issues on that whilst using it as local copy for my own flake, those have to be addressed before. As i am currently short on time, i am closing this pr and will open a new one, when its fixed.


Migrate some automatically generated scenario's (and protect them)

I the last year we have used ETM-tools to automatically generate scenario's on several occasions. These scenario's are currently not protected and are therefor not part of migrations. For some of them we gave the scenario numbers to clients for future reference.
Overview: unprotected scenarios for migration.xlsx

Is it possible to rerun the relevant migrations for these scenario's?
Is it possible to protect these scenario's so they are part of future migrations?
Will these extra scenario's (~ 1000) slow down future scenario's? If so, the scenario's in the tab "OPeningsbod_Stedin_0.8 do not have to be taken into account

More general question:

How should we deal with this in the future?

Is it possible to rerun the relevant migrations for these scenario's?

It's a bit of a pain, as we have to duplicate the migrations and run them for these specific scenarios, but it can be done.

Is it possible to protect these scenario's so they are part of future migrations?

Yes.

Will these extra scenario's (~ 1000) slow down future scenario's? If so, the scenario's in the tab "OPeningsbod_Stedin_0.8 do not have to be taken into account

It will slow down future migrations a little, but I'm not too worried about that. If you want the Stedin scenarios to be kept up-to-date, we'll have to migrate and protect them.

How should we deal with this in the future?

I think the etm-tools script(s) used to create these scenarios should have an option to protect the scenarios when they're created. I'm guessing cp-scenario was the tool which was used?

It's a bit of a pain, as we have to duplicate the migrations and run them for these specific scenarios, but it can be done.

What is your time estimation?

I think the etm-tools script(s) used to create these scenarios should have an option to protect the scenarios when they're created. I'm guessing cp-scenario was the tool which was used?

Sounds good!
Yes, we used a combination of  cp-scenario and csv-update-scenarios

I've pushed these migrations to the openingsbod-migrations branch.

the scenario's in the tab "OPeningsbod_Stedin_0.8 do not have to be taken into account

I did not include these scenarios, since "0.8" suggested that they might not be the finished versions? If I'm wrong about that, and you wish for them to be migrated and protected, it's trivial for me to add them before the branch is merged. As soon as you let me know how you want to proceed with the Stedin scenarios I can send the migrations to production.

I think the etm-tools script(s) used to create these scenarios should have an option to protect the scenarios when they're created.

This has been added. cp-scenario now accepts an optional --protect argument which will mark the created scenarios as protected.

I did not include these scenarios, since "0.8" suggested that they might not be the finished versions

Yes it's fine to leave them out!

Very nice @antw !
I will use some of the migrated scenario's next week :-)


Working with graphql-java 17.0beta

Any chance to get graphql-spring-boot working with graphql-java 17.0beta ? There's a lot of bugfixes in it we need in production.

Any chance to get graphql-spring-boot working with graphql-java 17.0beta ? There's a lot of bugfixes in it we need in production.

Yes! We need 17.0 beta too

Anyone can guess how could it happen?

Hi @dmtrkuzmin - that would be a question best directed to the graphql-java team (either as an issue or a discussion)
We'll update to graphql-java:17 shortly after it has been released.  That will likely coincide with graphql-java-kickstart v12.0.0

@softshape https://github.com/graphql-java-kickstart/graphql-spring-boot/pull/679
Some items we need to resolve, along with waiting for a 17.0 version of graphql-java-annotations.  I made a draft PR for that repo this morning

@softshape see #679. Some items we need to resolve, along with waiting for a 17.0 version of graphql-java-annotations. I made a draft PR for that repo this morning

graphql-java-annotations is updated, see https://github.com/Enigmatis/graphql-java-annotations/releases/tag/v9.0

@softshape - you're on the ball.
graphql-java released 17.2 only a few days ago with a handful of fixes.   We're looking to have https://github.com/Enigmatis/graphql-java-annotations/pull/280 and https://github.com/graphql-java-kickstart/graphql-java-tools/pull/575 merged and re-released

https://github.com/graphql-java-kickstart/graphql-spring-boot/pull/711

@oliemansm - annotations and tools both updated to 17.2.  Next is to release servlet 12.0.0

Next is to release servlet 12.0.0

Any plans for that?

@softshape We'll have to double check any open issues and then release it. Will try to do that this weekend.


Update go to v1.19

Signed-off-by: joshvanl<EMAIL_ADDRESS>Updates go modules and Docker image golang version to v1.19
/hold
Until jetstack/testing has been updated

/retest all

/test all


Community contributions

Hi! Any chances to accept community contributions?
I'm willing to help.

Hi @CarlosHAraujo
community contributions are welcome at any time.


Pydantic 2 does not support all of the V1 capabilities

hello. Trying to launch zwave-js-server-python, but it terminates with import error.
Install was done with pip3 install zwave-js-server-python
Launching it, I get the error below:
$ ./zwave-js-server-python
Traceback (most recent call last):
  File "./zwave-js-server-python", line 5, in <module>
    from zwave_js_server.__main__ import main
  File "/home/chr/.local/lib/python3.8/site-packages/zwave_js_server/__main__.py", line 9, in <module>
    from .client import Client
  File "/home/chr/.local/lib/python3.8/site-packages/zwave_js_server/client.py", line 28, in <module>
    from .model.driver import Driver
  File "/home/chr/.local/lib/python3.8/site-packages/zwave_js_server/model/driver.py", line 4, in <module>
    from pydantic import create_model_from_typeddict
  File "/home/chr/.local/lib/python3.8/site-packages/pydantic/__init__.py", line 218, in __getattr__
    return _getattr_migration(attr_name)
  File "/home/chr/.local/lib/python3.8/site-packages/pydantic/_migration.py", line 300, in wrapper
    raise PydanticImportError(f'`{import_path}` has been removed in V2.')
pydantic.errors.PydanticImportError: `pydantic:create_model_from_typeddict` has been removed in V2.

For further information visit https://errors.pydantic.dev/2.4/u/import-error

Downgrade pydantic to 1.10 and everything should work as is. Thanks for the report though, maybe we aren't as ready for pydantic 2 as we thought

np. happy to have helped testing.
thanks for a nice client library!

It seems like its available in the v1 shims, so that is surprising:
$ pip3 install pydantic==2.4.2
$ python3
>>> from pydantic.v1 import create_model_from_typeddict
>>>

hmm that's weird. @chrand is it possible you were on an earlier version of v2 that didn't have this shim?

Is this just an older version of zwave-js-server-python without the shims? Seems like it could be based on the line numbers.


Tracking issue: docs.rs leaks memory, causing production outages

We started noticing that docs.rs occasionally leaks gigabytes of memory at once, causing production outages due to the excessive amount of used RAM.

At the moment we're investigating what the root cause is.

Possibly fixed by #666. Since it's intermittent, we won't know for a while, though.

We haven't had any spikes of this sort in a week, are you comfortable closing this?

Hmm, we don't have any spikes, but we're still using 2 more GB of RAM at rest than after a server restart ... maybe it's worth keeping this open.

Someone on hackernews suggested using processes instead of threads, which would automatically clean up resources on panics: https://news.ycombinator.com/item?id=22946237
Not sure how crucial that is at the moment, but if we start having issues again it's certainly something to consider.

That's true, but I think the main concern in my mind right now is the high baseline memory usage. I wouldn't expect a docs.rs idling (i.e. not serving requests) to need, well, really any memory (a hundred megabytes seems more than enough). It would be helpful to narrow down what is using memory in the current process architecture.

I'm going to close this since we haven't had trouble with leaks as such - we might be running into buffer bloat or something, but given that we're only using 3 GB out of the 15 GB available I don't think that's a big deal.


Custom binding to close link hints

Currently I press e.g. f to open link hints and Esc to close them again. If I choose, I can rebind another key/combo to open link hints. However, I don't think it's possible to rebind any key besides Esc to close them.

Above: binding options for opening but not closing link hints.
My use case: I'm  creating a configuration full of Emacs-like bindings. I want to bind ctrl + g to close link hints.
If this is possible, I would love to know how to do it. If not, then I suppose this is a feature request.

Maybe relevant https://github.com/lusakasa/saka-key/issues/51


Multiple NetworkManagers detected in the scene. Only one NetworkManager can exist at a time

I'm getting error when calling stophost in networkmanager "Multiple NetworkManagers detected in the scene. Only one NetworkManager can exist at a time. The duplicate NetworkManager will be destroyed".

The error occurs when In the empty gameobject I name it RoomManager and I've added components namely NetworkRoomManager, NetworkDiscovery, NetworkDiscoveryHud and in the NetworkDiscoveryHud script I've added this
void Update()
{
    if (Input.GetKeyDown("space"))
    {
        NetworkManager.singleton.StopHost();
    }
}

But when I remove the NetworkDiscovery and NetworkDiscoveryHUD components and replace it with NetworkManagerHUD and call the stop host button it works just like in room examples and it works. But I really needed the NetworkDiscovery and NetworkManager
Then after getting that error the RoomManager gameobject is missing.
OS: windows 10
Build target: PC\Standalone
Unity version: 2020.1.17f1

Cannot reproduce in latest Mirror and Unity 2019.4.x LTS.  Should be fine in 2020.3.x as well.


long-lived failures can generate unhandled exceptions

e.g.
Unhandled rejection Error: DEL can't be processed. The connection has already been closed.
    at RedisClient.send_command (/project/node_modules/orchard/node_modules/redis/index.js:788:23)
    at RedisClient.(anonymous function).RedisClient.(anonymous function) (/project/node_modules/orchard/node_modules/redis/index.js:966:25)
    at RedisClient.tryCatcher (/project/node_modules/orchard/node_modules/bluebird/js/release/util.js:16:23)
    at RedisClient.ret (eval at <anonymous> (/project/node_modules/orchard/node_modules/bluebird/js/release/promisify.js:184:12), <anonymous>:13:23)
    at remove (/project/node_modules/orchard/index.js:194:20)
    at tryCatcher (/project/node_modules/orchard/node_modules/bluebird/js/release/util.js:16:23)
    at Promise._settlePromiseFromHandler (/project/node_modules/orchard/node_modules/bluebird/js/release/promise.js:497:31)
    at Promise._settlePromise (/project/node_modules/orchard/node_modules/bluebird/js/release/promise.js:555:18)
    at Promise._settlePromise0 (/project/node_modules/orchard/node_modules/bluebird/js/release/promise.js:600:10)
    at Promise._settlePromises (/project/node_modules/orchard/node_modules/bluebird/js/release/promise.js:683:18)
    at Async._drainQueue (/project/node_modules/orchard/node_modules/bluebird/js/release/async.js:125:16)
    at Async._drainQueues (/project/node_modules/orchard/node_modules/bluebird/js/release/async.js:135:10)
    at Async.drainQueues (/project/node_modules/orchard/node_modules/bluebird/js/release/async.js:16:14)
    at process._tickCallback (node.js:458:13)

orchard should catch these errors and emit them but allow any through-bound request to continue

closing as expected for long-lived delete failures


Always have a name for gltf2 mesh, material and skins.

Co-authored-by: @Lcbx
Always have names for gltf2 meshes in the new import dialog.
Can you try?
Related to https://github.com/godotengine/godot/pull/46783. See also https://github.com/godotengine/godot/pull/47312.

Thanks!


Provide a starter kit with  angular 8 and version 4

Issue type

[ ] bug report
[x] feature request
[x] question about the decisions made in the repository

Issue description
Is there any plan to provide a starter kit with angular 8 and nubular 4 or update the current starter kit branch!
Angular, Nebular
Angular 8 Nubular 4

Yeah its time to update the starter kit atleast in branch, to update current ngx admin its very cumbersome

But you did it already http://akveo.com/ngx-admin/pages/dashboard?utm_source=nebular_documentation&utm_medium=demo_button
please share the code of this link

@dj-fiorex  that's not the starter kit

duplicate of #2125

Closing as duplicate #2125


How to use it with SwipeRefreshLayout?

Thanks, it solved all my problems with scrolling, CollapsingToolbarLayout and ViewPager!
But there is a new problem and I do not know how to solve it:
I have to put  header in the NestedScrollView, but NestedScrollView is inside SwipeRefreshLayout and it is not visible because it is covered under AppBar.
If I put header before SwipeRefreshLayout, then NestedScrollView is scroll simultaneously with AppBar.

Can you post your layout here?

I got what you mean. You need to define these methods getActionBarSize() and getHeaderHeight(), then use below code:
    int actionBarSize = getActionBarSize();
    int progressViewStart = getHeaderHeight();
    int progressViewEnd = progressViewStart + (int) (actionBarSize * 1.5f);
    vSwipeRefreshLayout.setProgressViewOffset(true, progressViewStart, progressViewEnd);

Thank you, it works :)

Sweet


proper treatment of error messages

I wonder about the output here.
As I understand we result in the test result state "unknown" because we find an error (Could not set variable...). This is no "unkown exception".
I would expect the following:
Error: Could not set variable 'params['global']['teststring_bench']' with value 'I am the 'bench1' configuration of exercise 08'!
then:
BuiltIn().unknown()
No traceback, test-result "unknown".
General:
A traceback indicates for me a severe unhandled issue in the testsuites-management or robotframework core (or anywhere else).
Our implementations should always consider all possible error scenarios that it never comes to a traceback.
A handled error should never end with a traceback.
UNKNOWN - Unknown exception occurs. Details: Could not set variable 'params['global']['teststring_bench']' with value 'I am the 'bench1' configuration of exercise 08'!
DEBUG - Traceback (most recent call last):
  File "D:\RobotFramework\python39\lib\site-packages\RobotFramework_TestsuitesManagement\__init__.py", line 67, in run_keyword
    return DynamicCore.run_keyword(self, name, args, kwargs)
  File "D:\RobotFramework\python39\lib\site-packages\robotlibcore.py", line 105, in run_keyword
    return self.keywords[name](*args, **(kwargs or {}))
  File "D:\RobotFramework\python39\lib\site-packages\RobotFramework_TestsuitesManagement\Keywords\CSetup.py", line 70, in testsuite_setup
    BuiltIn().unknown(CConfig.sLoadedCfgError)
  File "D:\RobotFramework\python39\lib\site-packages\robotframework-4.1.3-py3.9.egg\robot\libraries\BuiltIn.py", line 562, in unknown
    raise UnknownAssertionError(msg) if msg else UnknownAssertionError()

Hello Thomas,
In case we want to remove traceback for all Robot keywords which we define in testsuitesmanagement library, I will comment out overwritten method "def run_keyword(self, name, args, kwargs):" in init.py of testsuitesmanagement package.
Otherwise, If you want to remove traceback log for unknown() case only, Cuong has to modify code in Robot Framework core.
Thank you,
Son

Hi Son,
Generally:
we need tracebacks if we really have a crash.
But we should whenever possible consider possible crashs in our code and handle them. If we handle this, then we don't need a traceback, but a speaking error message.
In this case we have to take care that DynamicCore.run_keyword(self, name, args, kwargs) raises no exception by handling all possible exceptions in our keywords.
So I think Cuong has to avoid the traceback in case of  unknown state.
Thank you,
Thomas

Hello Thomas,
Yes, I already discussed with Cuong on this ticket, and he said he will modify in Robot FW core to avoid this traceback.
Thank you,
Son

very good!

Hello @milanac030988 ,
Could you please update the status for this ticket?
Thank you,
Son

Hello @test-fullautomation
I have reviewed your expectation in the meeting regarding setting unknown status for import errors and found the following:

Current status: The current mechanism of Robotframework is that when there is an error in the import section(Library, Resource, Variables), it will print an error log line '[ERROR]...' but still continue executing the test file as usual.

By changing it, I want you to confirm that you would like to change its current behavior and treat it as a normal Unknown exception (raise unknown and skip executing the test).

I also have a question to ask for your opinion, whether you want to treat DataErrors as an Unknown exception. As far as I can see, all DataErrors (listed in the attachment) can be reasonably treated as Unknown.

Please let me know your opinion.
DataErrorList.txt

Hi Cuong,
I assume that if somebody imports a file, that this has a meaning.
So, if we don't stop execution with unknown, then during test-run an error will occur due to missing resource or keyword.
Therefore "unknown" and skipping executing the test is meaningful for me in this case.
Yes, as far as I see DataErrorList.txt is quite similar to where we use "unknown" in TML.
So, make them all "unknown".
Thank you,
Thomas


descriptor_read_value_failed Callback

If a descriptor value fails to be read, the Descriptor method read_value will call:
self.service.device.descriptor_read_value_failed(self, error=error).
This causes an error because the Descriptor class has no 'service' property.
The line should be corrected to:
self.characteristic.service.device.descriptor_read_value_failed(self, error=error).
This Class exists in gatt_linux.py. The offending code is on line 541 of this file.

Would you mind creating a PR which we can merge?

On 14. Oct 2019, at 20:35, jasonspage<EMAIL_ADDRESS>wrote:

If a descriptor value fails to be read, the Descriptor method read_value will call:
self.service.device.descriptor_read_value_failed(self, error=error).
This causes an error because the Descriptor class has no 'service' property.
The line should be corrected to:
self.characteristic.service.device.descriptor_read_value_failed(self, error=error).
This Class exists in gatt_linux.py. The offending code is on line 541 of this file.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.


Doom git hooks installing on my home directory

What did you expect to happen?
I am working on random git bare repository and when I try to commit, the doom hook tells me I cannot
What actually happened?
$ git commit -m "something"

 hook: master

> Executing 'doom ci hook-commit-msg /Users/poop/.cfg/COMMIT_EDITMSG' with Emacs 27.2 at 2021-12-09 03:57:58
  > Linting 1 commits
    > CURRENT multiplatform
      ! Subject is short (<20); are you sure it's descriptive enough?
      x Commit has no detectable type
      x Commit has no summary
  ! Warnings: 1
  ! Failures: 2

  See https://docs.doomemacs.org/-/conventions/git-commits

Describe your attempts to resolve the issue
$ rm ~/.githooks/pre-push
$ rm ~/.githooks/commit-msg

worked pretty well
Steps to reproduce
Fresh install of Doom on a new computer.
$ rm -rf ~/.emacs.d
$ git clone --depth 1 https://github.com/hlissner/doom-emacs ~/.emacs.d
$ ~/.emacs.d/bin/doom install

I have doom in another pc since a year ago and this isn't a problem, i Imagine it is something with the install
System Information
OSX

For the record it happened again to someone else, also on MacOS
So the issue seems to be that the default-directory let-binding to get the path to hooks isn’t working in those 2 cases.
As the doc of call-process suggests, if it can’t find a proper directory, the working directory of the process will be ~, which deploys hooks for all repos of the user.
Since call-process has a C implementation relying on another C subroutine, I didn’t really look much further into this. Especially if it turns out a MacOS specific thing, since there would be extra patches to look for (in the recipes used to build/install Emacs on the OS), and I don’t have apple hardware anyway

1c1ad3a adds a --no-hooks switch to doom install, which should allow folks to get around this issue, so I'll consider this resolved. Let me know if that isn't the case and I'll reopen it. Thanks for bringing it to my attention!

I'm using the git config option core.hooksPath to set some global hooks that should run on all my repositories. When I ran doom install it replaced both my commit-msg and pre-push hooks with the doom's hooks. Luckily I keep my git hooks under source control, so I could restore them.
This line is probably the culprit
https://github.com/hlissner/doom-emacs/blob/fca8bd7f3fa697a91774c2ddedcd1a47cd7da01a/core/cli/ci.el#L18
because git rev-parse --git-path hooks  is returning the global hook path unless it's been overridden locally (e.g via git config --local core.hooksPath .git/hooks)


Basalt thick roofs broken

Whenever i try to build a thick roof out of basalt the materials are consumed, the work is done, the "new roof" sprite appears, but the roof doesn't get added and the tile remains uncovered.
The granite and limestone roofs for example work fine.

By this i mean that, the lava rock / basalt added by a different mod appears to be buildable and correctly shows hitpoints, and work amount, but is not actually placed.

If you are still using the mod and this is still an issue, can you be more specific about what mod is adding basalt?


[6.x] stopped in maker-zip on win32

[x ] I have read the contribution documentation for this project.
[x ] I agree to follow the code of conduct that this project follows, as appropriate.
[x ] I have searched the issue tracker for an issue that matches the one I want to file, without success.

Please describe your issue:
When I run electron-forge make in my application, It stopped at Making for target: zip - On platform: win32 - For arch: x64. Then, I add some debug in maker-zip and cross-zip, I found It stopped beacause of running powershell.exe.
√ Packaging Application
Making for the following targets: zip, squirrel
- Making for target: zip - On platform: win32 - For arch: x64
2019-02-28T05:10:04.140Z electron-forge:cross-zip ===================zip
2019-02-28T05:10:04.140Z electron-forge:cross-zip ===================doZip
2019-02-28T05:10:04.141Z electron-forge:cross-zip ===================doZip2 powershell.exe -nologo -noprofile -command "& { Add-Type -A 'System.IO.Compression.FileSystem'; [IO.Compression.ZipFile]::CreateFromDirectory('D:\workspace\datav-component-dev\app\out\DComponent-win32-x64', 'D:\workspace\datav-component-dev\app\out\make\DComponent-win32-x64-0.0.6.zip'); }"
--

And I guess that there has some mistake in cross-zip, There is a child_procss exec powershell.exe.
So, I run the cmd powershell.exe -nologo -noprofile -command "& { Add-Type -A 'System.IO.Compression.FileSystem'; [IO.Compression.ZipFile]::CreateFromDirectory('D:\workspace\datav-component-dev\app\out\DComponent-win32-x64', 'D:\workspace\datav-component-dev\app\out\make\DComponent-win32-x64-0.0.6.zip'); }" in the CMD.
But, the CMD show me:
Add-Type: 无法添加类型。找不到程序集“System.IO.Compression.FileSystem”。
所在位置 行：1 字符：13
+ & {  Add-Type 　<<<<　-A 'System.IO.Compression.FileSystem'; [IO.Compression.ZipFile]::CreateFromDirectory('D:\workspace\datav-component-dev\app\out\DComponent-win32-x64', 'D:\workspace\datav-component-dev\app\out\make\DComponent-win32-x64-0.0.6.zip'); }
+ CategoryInfo : InvalidData: (:) [Add-Type], InvalidOperationException
+ FullyQualifiedErrorId: ASSEMBLY_LOAD_ERRORS, Microsoft.PowerShell.Commands.AddTypeCommand

There has some Chinese, It means not found Assembly. But I'm sure I have 'System.IO.Compression.FileSystem.dll', It's in my C:\Windows\Microsoft.NET\Framework\v4.0.30319.
For this error, I tried two methods.

I download gacutil.exe to add 'System.IO.Compression.FileSystem.dll' in my GAC.
I add  C:\Windows\Microsoft.NET\Framework\v4.0.30319 to my PATH.

But, they don't work.
What does your config.forge data in package.json look like?
const path = require('path');
const { AUTO_UPDATER_URL, AUTO_UPDATER_APP_ID, AUTO_UPDATER_CHANNEL_ID }=require('../config');

module.exports = {
  packagerConfig: {
    dir: path.join(__dirname, './'),
    asar: true,
    ignore: [
      'main/',
      'renderer/',
      'com-app/static/',
      'main.dev.js',
      'out/'
    ],
    out: 'out',
    platform: 'all',
    appId: 'com.datav-component-develop.app',
    appCategoryType: 'public.app-category.developer-tools',
    icon: './resources/icon',
    extendInfo: {
      NSAppTransportSecurity: {
        NSAllowsArbitraryLoads: true
      }
    },
    osxSign: {
      identity: process.env.APP_IDENTITY,
      'gatekeeper-assess': false
    }
  },
  publishers: [
    {
      name: '@electron-forge/publisher-nucleus',
      config: {
        host: AUTO_UPDATER_URL,
        appId: AUTO_UPDATER_APP_ID,
        channelId: AUTO_UPDATER_CHANNEL_ID,
        token: process.env.NUCLEUS_TOKEN, // This should be set securely
      },
    },
  ],
  makers: [
    {
      name: '@electron-forge/maker-zip'
    }
  ]
};

According to https://github.com/feross/cross-zip#windows-users, you need .NET Framework 4.5 or later. I can't really help you much further than that, because I'm not a Windows user.

Thanks~! I successed when I upgraded my Powershell.


remove deprecated infastructure parameter from graph creation functions

The infrastructure parameter in graph creation functions was deprecated in favor of the flexible custom_filter parameter in a previous release. This PR removes it from the codebase. See also #477.

Coverage increased (+0.1%) to 92.946% when pulling e706e7d7e7e6cf6dedd2704d26dc580dffbb81b0 on feature into 8e32f4b03b46a8b607804aff2e43e419f4bbe341 on master.


Error in Azure Function: No valid combination of account information found.

Please provide us with the following information:

This issue is for a: (mark with an x)
- [x ] bug report -> please search issues before submitting
- [ ] feature request
- [ ] documentation issue or request
- [ ] regression (a behavior that used to work and stopped in a new release)

Minimal steps to reproduce

Set up the tutorial as intended and drop one file in the input container.

Any log messages given by the failure

2023-03-08 01:14:07.197 Executing 'Functions.BatchTrigger1' (Reason='New blob detected(LogsAndContainerScan): input/scan01.pdf', Id=39d82eed-9181-416e-a640-d0e093bbff6d) Information 2023-03-08 01:14:07.197 Trigger Details: MessageId: 6cdd12d8-0c1a-4342-bbd2-10e868f55126, DequeueCount: 1, InsertedOn: 2023-03-08T01:14:07.000+00:00, BlobCreated: 2023-03-08T01:14:00.000+00:00, BlobLastModified: 2023-03-08T01:14:00.000+00:00 Information 2023-03-08 01:14:07.912 Creating job... Information 2023-03-08 01:14:08.005 No valid combination of account information found. Error 2023-03-08 01:14:08.006 Executed 'Functions.BatchTrigger1' (Failed, Id=39d82eed-9181-416e-a640-d0e093bbff6d, Duration=822ms) Error 2023-03-08 01:14:08.008 No valid combination of account information found.

Expected/desired behavior

Funtion runs properly

OS and Version?

Windows 10

Versions

Mention any other details that might be useful
I've followed the instructions carefully, all my credentials in run.csx appear to be accurate. The only question would be, does my output SAS need to be the URL or the Key?

Thanks! We'll be in touch soon.

User error. I had the key for the container in place of the connection string. All is working as intended now. Thanks!

User error. I had the key for the container in place of the connection string. All is working as intended now. Thanks!

Could you please explain more here for reference? Thanks in advance!


improvement support support get mysql information_schema's table and clickhouse system's table

Proposed changes
Issue Number: close #xxx

Further comments
If this is a relatively large or complex change, kick off the discussion at<EMAIL_ADDRESS>by explaining why you chose the solution you did and what alternatives you considered, etc...

run buildall

run buildall


Bug/local_quali_campaign

There was an issue getting the inclusive props and exlusive props to load.
This was happening when there was a hard refresh of the page.
Now that these props have been moved to the computed property it is behaving as expected.

Fixed for batches and campaigns


Investigate the gas cost for deploying QuorumHistoryPairFactory deterministically

📚 Context
When deploying the QuorumHistoryPairFactory deterministically, specifically we are talking about the deployment of the history here, we use an auxiliary function calculateCompoundSalt (originally proposed by Gui) to compute the compound salt of all parameters instead of directly using _salt.
By doing this, attackers will not be able to front run the deployment of history by using the same _salt but different _validators and _shares, thus occupying the deterministic deployment address of history.
However, this attack is expensive for attackers because there are 2 contract deployments. And the attack consequence is likely not severe, because if being front-run, the user can simply choose another salt.
The users' cost to prevent this attack, via calling calculateCompoundSalt, is what to be investigated under this issue.
This issue is specifically for QuorumHistoryPairFactory because its calculation of compound salt involves 2 arrays whose size can be large if the quorum is large.

Superseded by #130 (see solution in comments).


fix profile image for zola 0.14

zola 0.14.0 introduced a breaking change, resize_image function now
returns an object instead of just the URL.

Thanks!


switching view type causes crash in staging

switch to staging, tap least bids, tap grid, crash
going from grid view to any other view type and back to grid causes this crash

Opened #473 about this – definitely a bug.


FLINK-28171 [flink-kubernates] enable add appProtocol via the configuration and verify it is not overridden by Default port defintion

What is the purpose of the change
enable the job manager and task manager communicate in a Kubernetes cluster with Istio and mTLS enabled.
Brief change log
Add the “appProtocol” in the task manager and job manager configuration, verify they are not overridden by the default definition in the decorators
Verifying this change
This change is already covered by existing tests
Does this pull request potentially affect one of the following parts:

Dependencies (does it add or upgrade a dependency):  no
The public API, i.e., is any changed class annotated with @Public(Evolving):  no
The serializers: no
The runtime per-record code paths (performance sensitive): no
Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn, ZooKeeper: (yes / no / don't know)
The S3 file system connector: no

Documentation

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

LGTM! Thanks!

added unit tests. thanks

@wangyang0918 can you please review. thanks

Allowing myself to give this a bump. Any way to prioritize the review?

@sigalite I think you'll need to rebase and squash your commits, since your PR contains merge commits and it can't be merged as-is.

@sigalite You're merging the branch into your PR, but you need to rebase. There's shouldn't be any "merge into" commits in your PR

Thanks @MartijnVisser, i'm afraid i had issues withe rebase and squashe. created new PR
https://github.com/apache/flink/pull/22936

please review https://github.com/apache/flink/pull/22936


Enabling and improving whisper file header caching

Currently this setting is not exposed through carbon, I have created a few branches that

Expose this setting through carbon-cache options
Creates a notion of entry which encapsulates a time stamp in addition to info
Allows carbon cache to control the ageing

I do not expect my first proposal to be accepted but would like to start this conversation as caching would be very useful in order to decrease the number of disk iops
To this end I am proposing
https://github.com/graphite-project/whisper/pull/157
https://github.com/graphite-project/carbon/pull/523
for your consideration

Hi @pu239ppy !
It will be really great if you able to describe your change in couple of words - what's are you trying to solve and how?

In short I am trying to reduce the number of io ops carbon-cache imposes on
the disk.  One way to do this is decrease updates per second, but caching
the wsp file header is great as well since we now do not have to perform
reads for every write.  I was going to implement it myself, but noticed
that it is already there.  My changes allow admins to enable header caching
through a carbon [cache] setting, and also add time stamps (whisper code)
and ageing operations to (carbon code) carbon.
On Feb 18, 2016 04:27, "Denis Zhdanov"<EMAIL_ADDRESS>wrote:

Hi @pu239ppy https://github.com/pu239ppy !
It will be really great if you able to describe your change in couple of
words - what's are you trying to solve and how?
—
Reply to this email directly or view it on GitHub
https://github.com/graphite-project/whisper/issues/158#issuecomment-185624581
.

I commented on https://github.com/graphite-project/carbon/pull/523 without realizing there were multiple places this issue was filed. Please read that comment.

Brian, I replied, but also including the reply here for visibility.
Brian, this setting is not mandatory, and in fact disabled by default.
While it would be possible to have a unified cache with a caching system I
am reluctant to add more components (caching layer such as redis) to
carbon.


Internal: Flatten imports and use explicit extensions

This is a big looking PR but really on does two small things:
a.) Uses no-relative-parent-imports eslint rule to flatten imports and enforce explicit namespaces.
b.) Turns on file extensions by default (something that Ryan Dahl lists as a regret with Nodes module resolution system).
While this may make the packages/gestalt/src directory a lot bigger, I think it has serveral positive benefits of showing what stuff is shared in gestalt and allowing us to isolate parts of codebase (behaviors, layouts etc.)
You can see a quick tree-view of the results on my branch.

Deploy preview for gestalt ready!
Built with commit efc690b8552eda5f58aec8b5eac84a2146c175e1
https://deploy-preview-261--gestalt.netlify.com

Deploy preview for gestalt ready!
Built with commit 19c5a3f48a977a4f839902d99f9b3a972eb85431
https://deploy-preview-261--gestalt.netlify.com

Warnings

:warning:

:memo: CHANGELOG - Please add a CHANGELOG.md entry for your changes

  Generated by :no_entry_sign: dangerJS

@chrislloyd seems like this might break all the Source links for a while. Might be good to do a release soon after


chore: removed unsupported speech samples

go/cloud-ai-2021-snippet-cleanup
Devsite:
cl/363930391 [pending]

@munkhuushmgl let me know when the CL has been merged and we have no more warnings from snippet-bot. Thanks.

Unrelated failures:

Storage test failures being tracked in #1272.
Asset test failure tracked by #1278.

@amanda-tarafa CL is submitted and published.

All failures are unrelated and tracked.
Force merging.


Fix ResourceExhaustedError

In case of MNIST, ResourceExhaustedError occurs every time. I think it depends on Deep Learning parameters, so we have to identify the parameters.

This error does not always occurs. No error occurred after changed parameter ranges. It has something to do with parameters.


Style/RedundantLineContinuation flagging multiline strings

The cop seems to target multi line strings when the following line starts with interpolation #{...}

Expected behavior
I expect the cop not to flag lines like this:
str = "abc \
  #{foo}"

Actual behavior
First line above gets flagged by redundant line continuation cop.
Steps to reproduce the problem
Run rubocop on a file containing the code mentioned above.
RuboCop version
bund0adb10d38394:/var/app$ bundle exec rubocop -V
1.49.0 (using Parser <IP_ADDRESS>, rubocop-ast 1.28.0, running on ruby 3.2.2) [x86_64-linux-musl]

This issue is a dup with #11758 and resolved by #11759.

@koic I'm not entirely sure it is - I have two strings and only one of them (the one with #{}) gets flagged. That issue was about strings in general. Has that fix been released in 1.49.0?

Not yet released. It will probably be resolved in 1.50.0 that next release.

1.50 is now out!

And that indeed fixed it, thank you.


Fixes an issue not handling paths containing a space

Batch file won't run properly if there the path contains a space.
For example, if the path is C:\Stable Diffusion it will break when trying to run Python, specifically on line 29. With this change, the referenced Python path is enclosed in quotations to support paths containing a space. I suppose this will also fix the batch file not running for paths with certain special characters that are reserved characters for cmd.

@Infinitay, thank you.


Vim registers not working inside tmux

Steps to reproduce

Open hyperterm
Open tmux tmux
Open vim vim somefile
Copy something. say yy
Paste p

It gives an error

E353: Nothing in register *

If you're running macOS 10.12 Sierra you might have run into this problem:
https://github.com/tmux/tmux/issues/543

@bramkok: Yes, I'm using macOS Sierra. This problem was not there for iterm.
Thank you for guiding me to the right path.
I'd prefer to close this issue as its causing because of tmux.
Please share your thoughts on the same.

Frustratingly, the tmux issue also means that {vim clipboard registers, pbpaste} aren't viable workarounds for #484. 😓

Add the following into your .vimrc
if $TMUX == ''     set clipboard+=unnamed endif
Reference:
https://stackoverflow.com/questions/11404800/fix-vim-tmux-yank-paste-on-unnamed-register


Option to switch off blinking blue status led

Is it possible to create an option to switch on/off the blinking of the bleu status led?
Thank you!

Yes, we can.

Added it to the dev branch. Will be in next binary release.

it's in release v0.8.0


Update lcobucci/jwt dependency version to be compatible with php7.3

Hi,
Actually, i have an error when i try with php 7.3. I think you have to use lcobucci/jwt in version 3.3 now compatible with php 7.3 : https://github.com/lcobucci/jwt/issues/282
Thanks,
Alex

for me it's working with PHP 7.3.3 and lcobucci/jwt 3.2.5?!

I don't understand why but now it's working too. Thanks for your answer


revised according to Pascale and Lynette suggestions

From Lynette:
============
Below is the  merged list of changes - mine are marked with (L);  Pascale’s observations are marked with (P).
*** Merged list of fixes to be done ***
(P) water access was supposed to be a node - water management, water commodity and water security were to be removed because of overlap
(P) water supply? don't remember seeing before - might overlap with water safety/water bodies/water access...
(L) Water safety (under living_condition) – does this include WASH as a synonym (water, sanitation, hygiene)? This term occurs a lot but it’s not clear if it should go under “water_safety” or “sanitation_and_hygiene”.  Should we reorganize this to have Water_sanitation_hygiene as a concept under living_condition, and then water_safety and sanitation_and_hygiene under that?
(L) food_intake is missing – per slide 11, should be under nutrition; right now, nutrition has only malnutrition and food_diversity
(P) under nutrition,  breast feeding also missing
(P) food stability should be just stability? – L&B say no, leave as is
(P) tension was supposed to be in conflict
(L) under natural_resources, there is both land and land_availability – seems like these should be merged?
(L) slide 13 says “condition branch could be removed” – but it’s still there, with famine, food_security, tension and trend under it. Slide suggested moving famine under  “crisis_and_disaster” and leaving food_security directly under causal factor (and ignoring or filtering “trend”)
(L) I looked at “trend” – it seems to include anything w the word “expected” – also, trend should be filtered or simply removed from the ontology (which should also have the effect of ‘filtering’ it.
(P) human migration was supposed to be the box name instead of migration

This is my comments:

(P) water access was supposed to be a node - water management, water commodity and water security were to be removed because of overlap
(P) water supply? don't remember seeing before - might overlap with water safety/water bodies/water access...
Folded water_management, water_commodity, water_security, water_insecurity, water_supply INTO water_access

(L) Water safety (under living_condition) – does this include WASH as a synonym (water, sanitation, hygiene)? This term occurs a lot but it’s not clear if it should go under “water_safety” or “sanitation_and_hygiene”.  Should we reorganize this to have Water_sanitation_hygiene as a concept under living_condition, and then water_safety and sanitation_and_hygiene under that?
WASH is really a combination of safe water, sanitation, and hygiene (education). I'm going to guess that most occurrences of "WASH" appears as Interventions?
There isn't really a concise Intervention node I could place "WASH" into, so I did the following:

added "WASH facilities" as examplar to interventions/building_construction/communal_washing_and_bathing_facilities
added "WASH packages" as examplar to interventions/provision_of_goods_and_services/basic_minimal_household_hygiene_item_package

(L) food_intake is missing – per slide 11, should be under nutrition; right now, nutrition has only malnutrition and food_diversity
(P) under nutrition,  breast feeding also missing
I'm seeing these now. I'm guessing Becky added them.

(P) tension was supposed to be in conflict
I've moved it to under conflict. Although, 'tension' has examplars such as stress, distress, challenge, hardship, burden, threatening, adversity, etc. So it is more general, than "political tension" which I'm guessing is what you are after.

(L) under natural_resources, there is both land and land_availability – seems like these should be merged?
The examplars in "land" are: area, land, mountain, mt, wetland, sand, flood plains, greenbelt, agricultural land, arable land, cultivated area

@Becky: These seem to be more 'entity' like. Thoughts?

(L) slide 13 says “condition branch could be removed” – but it’s still there, with famine, food_security, tension and trend under it. Slide suggested moving famine under  “crisis_and_disaster” and leaving food_security directly under causal factor (and ignoring or filtering “trend”)

I've moved famine under crisis_and_diaster
I've removed 'condition' box, and thus moved trend, food_security, and food_insecurity directly under causal_factor.

(L) I looked at “trend” – it seems to include anything w the word “expected” – also, trend should be filtered or simply removed from the ontology (which should also have the effect of ‘filtering’ it.
I remember that Ben G. suggested keeping it, but said he would filter it out on his end.

(P) human migration was supposed to be the box name instead of migration
The migration box currently contains the following

    - migration:
      - human_migration
      - hosting_idps
      - emigration
      - immigration
      - migration_returnees
      - seasonal_migration

So I'm not changing 'migration' to 'human migration', since that would clash with its child node 'human_migration'.

Thanks @chanys ! Some comments/replies inline:

This is my comments:

(P) water access was supposed to be a node - water management, water commodity and water security were to be removed because of overlap
(P) water supply? don't remember seeing before - might overlap with water safety/water bodies/water access...

Folded water_management, water_commodity, water_security, water_insecurity, water_supply INTO water_access

👍

(L) Water safety (under living_condition) – does this include WASH as a synonym (water, sanitation, hygiene)? This term occurs a lot but it’s not clear if it should go under “water_safety” or “sanitation_and_hygiene”.  Should we reorganize this to have Water_sanitation_hygiene as a concept under living_condition, and then water_safety and sanitation_and_hygiene under that?

WASH is really a combination of safe water, sanitation, and hygiene (education). I'm going to guess that most occurrences of "WASH" appears as Interventions?
There isn't really a concise Intervention node I could place "WASH" into, so I did the following:

added "WASH facilities" as examplar to interventions/building_construction/communal_washing_and_bathing_facilities
added "WASH packages" as examplar to interventions/provision_of_goods_and_services/basic_minimal_household_hygiene_item_package

👍

(L) food_intake is missing – per slide 11, should be under nutrition; right now, nutrition has only malnutrition and food_diversity
(P) under nutrition,  breast feeding also missing

I'm seeing these now. I'm guessing Becky added them.
nope -- maybe it's bc it's in there as breast_feeding not breastfeeding that it wasn't seen before?

(P) tension was supposed to be in conflict

I've moved it to under conflict. Although, 'tension' has examplars such as stress, distress, challenge, hardship, burden, threatening, adversity, etc. So it is more general, than "political tension" which I'm guessing is what you are after.

(L) under natural_resources, there is both land and land_availability – seems like these should be merged?

The examplars in "land" are: area, land, mountain, mt, wetland, sand, flood plains, greenbelt, agricultural land, arable land, cultivated area
@becky: These seem to be more 'entity' like. Thoughts?

agreed -- I can move them or remove them, I'll submit a second PR for this

(L) slide 13 says “condition branch could be removed” – but it’s still there, with famine, food_security, tension and trend under it. Slide suggested moving famine under  “crisis_and_disaster” and leaving food_security directly under causal factor (and ignoring or filtering “trend”)

I've moved famine under crisis_and_diaster
I've removed 'condition' box, and thus moved trend, food_security, and food_insecurity directly under causal_factor.

(L) I looked at “trend” – it seems to include anything w the word “expected” – also, trend should be filtered or simply removed from the ontology (which should also have the effect of ‘filtering’ it.

I remember that Ben G. suggested keeping it, but said he would filter it out on his end.

(P) human migration was supposed to be the box name instead of migration

The migration box currently contains the following

migration:
human_migration
hosting_idps
emigration
immigration
migration_returnees
seasonal_migration

So I'm not changing 'migration' to 'human migration', since that would clash with its child node 'human_migration'.


Update to hyper >=1.0

It would be great if dependency on hyper can be updated (to >= 1.0, ideally 1.1). This causes quite a big set of dependencies in my project stuck with older versions.

Thanks for creating this issue. I'm, working on it in https://github.com/alexliesenfeld/httpmock/tree/upgrade-hyper .

For some reason, https://github.com/alexliesenfeld/httpmock/pull/98 was not merged.

@alexliesenfeld I have migrated it in a private development branch. httpmock 0.8 will bring significant improvements but it still takes a bit time to get everything stable. So it’s done bot not shipped yet.

It has been 7 months since the last release.  When are you expecting to be able to release 0.8?
Maybe #98 could be merged and released as 0.7.1  which is mentioned as the next release in the CHANGELOG.md ?

When are you expecting to be able to release 0.8?

I expect the first alpha to be shipped in a few weeks.

Maybe https://github.com/alexliesenfeld/httpmock/pull/98 could be merged and released as 0.7.1 which is mentioned as the next release in the CHANGELOG.md ?

Releasing it in 0.7.1 would more or less require me to do the work twice, because httpmock was entirely rewritten for 0.8.0. I'm trying to put my available time 100% into shipping it. I hope you understand.

ok, looking forward to the alpha!

to clarify, https://crates.io/crates/httpmock/0.8.0-alpha.1 has been released.  Thanks.  Trying it out


EmbeddedKafka broken when using placeholder properties for topics

Affects Version(s): 2.3.0.M3
Unaffected Version(s): 2.3.0.M2
When upgrading from spring-kafka-test:2.2.0.M2 to spring-kafka-test:2.2.0.M3, it is no longer possible to use property placeholders for defining topics in @EmbeddedKafka annotation.
For example, @EmbeddedKafka(topics = ["\${some.topic}"]), stops working. See example here: https://github.com/catchin/spring-embedded-kafka-test
Stack trace:
Failed to evaluate condition [org.springframework.kafka.test.condition.EmbeddedKafkaCondition]
org.junit.jupiter.engine.execution.ConditionEvaluationException: Failed to evaluate condition [org.springframework.kafka.test.condition.EmbeddedKafkaCondition]
	at org.junit.jupiter.engine.execution.ConditionEvaluator.evaluationException(ConditionEvaluator.java:80)
	at org.junit.jupiter.engine.execution.ConditionEvaluator.evaluate(ConditionEvaluator.java:69)
	at org.junit.jupiter.engine.execution.ConditionEvaluator.lambda$evaluate$0(ConditionEvaluator.java:55)
	at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195)
	at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:177)
	at java.base/java.util.stream.StreamSpliterators$WrappingSpliterator.tryAdvance(StreamSpliterators.java:302)
	at java.base/java.util.stream.Streams$ConcatSpliterator.tryAdvance(Streams.java:723)
	at java.base/java.util.stream.ReferencePipeline.forEachWithCancel(ReferencePipeline.java:127)
	at java.base/java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:502)
	at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:488)
	at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474)
	at java.base/java.util.stream.FindOps$FindOp.evaluateSequential(FindOps.java:150)
	at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
	at java.base/java.util.stream.ReferencePipeline.findFirst(ReferencePipeline.java:543)
	at org.junit.jupiter.engine.execution.ConditionEvaluator.evaluate(ConditionEvaluator.java:57)
	at org.junit.jupiter.engine.descriptor.JupiterTestDescriptor.shouldBeSkipped(JupiterTestDescriptor.java:171)
	at org.junit.jupiter.engine.descriptor.JupiterTestDescriptor.shouldBeSkipped(JupiterTestDescriptor.java:54)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$checkWhetherSkipped$2(NodeTestTask.java:115)
	at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.checkWhetherSkipped(NodeTestTask.java:115)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:77)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1540)
	at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.invokeAll(SameThreadHierarchicalTestExecutorService.java:38)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$5(NodeTestTask.java:139)
	at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$7(NodeTestTask.java:125)
	at org.junit.platform.engine.support.hierarchical.Node.around(Node.java:135)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:123)
	at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:122)
	at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:80)
	at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.submit(SameThreadHierarchicalTestExecutorService.java:32)
	at org.junit.platform.engine.support.hierarchical.HierarchicalTestExecutor.execute(HierarchicalTestExecutor.java:57)
	at org.junit.platform.engine.support.hierarchical.HierarchicalTestEngine.execute(HierarchicalTestEngine.java:51)
	at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:220)
	at org.junit.platform.launcher.core.DefaultLauncher.lambda$execute$6(DefaultLauncher.java:188)
	at org.junit.platform.launcher.core.DefaultLauncher.withInterceptedStreams(DefaultLauncher.java:202)
	at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:181)
	at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:128)
	at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor$CollectAllTestClassesExecutor.processAllTestClasses(JUnitPlatformTestClassProcessor.java:102)
	at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor$CollectAllTestClassesExecutor.access$000(JUnitPlatformTestClassProcessor.java:82)
	at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor.stop(JUnitPlatformTestClassProcessor.java:78)
	at org.gradle.api.internal.tasks.testing.SuiteTestClassProcessor.stop(SuiteTestClassProcessor.java:61)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:35)
	at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)
	at org.gradle.internal.dispatch.ContextClassLoaderDispatch.dispatch(ContextClassLoaderDispatch.java:32)
	at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:93)
	at com.sun.proxy.$Proxy2.stop(Unknown Source)
	at org.gradle.api.internal.tasks.testing.worker.TestWorker.stop(TestWorker.java:132)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:35)
	at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)
	at org.gradle.internal.remote.internal.hub.MessageHubBackedObjectConnection$DispatchWrapper.dispatch(MessageHubBackedObjectConnection.java:175)
	at org.gradle.internal.remote.internal.hub.MessageHubBackedObjectConnection$DispatchWrapper.dispatch(MessageHubBackedObjectConnection.java:157)
	at org.gradle.internal.remote.internal.hub.MessageHub$Handler.run(MessageHub.java:404)
	at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:63)
	at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:46)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:55)
	at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: kafka.common.KafkaException:
	at org.springframework.kafka.test.EmbeddedKafkaBroker.createTopics(EmbeddedKafkaBroker.java:297)
	at org.springframework.kafka.test.EmbeddedKafkaBroker.lambda$createKafkaTopics$4(EmbeddedKafkaBroker.java:284)
	at org.springframework.kafka.test.EmbeddedKafkaBroker.doWithAdmin(EmbeddedKafkaBroker.java:311)
	at org.springframework.kafka.test.EmbeddedKafkaBroker.createKafkaTopics(EmbeddedKafkaBroker.java:283)
	at org.springframework.kafka.test.EmbeddedKafkaBroker.afterPropertiesSet(EmbeddedKafkaBroker.java:229)
	at org.springframework.kafka.test.condition.EmbeddedKafkaCondition.createBroker(EmbeddedKafkaCondition.java:145)
	at org.springframework.kafka.test.condition.EmbeddedKafkaCondition.evaluateExecutionCondition(EmbeddedKafkaCondition.java:97)
	at org.junit.jupiter.engine.execution.ConditionEvaluator.evaluate(ConditionEvaluator.java:64)
	... 66 more
Caused by: java.util.concurrent.ExecutionException: org.apache.kafka.common.errors.InvalidTopicException: Topic name "${some.topic}" is illegal, it contains a character other than ASCII alphanumerics, '.', '_' and '-'
	at org.apache.kafka.common.internals.KafkaFutureImpl.wrapAndThrow(KafkaFutureImpl.java:45)
	at org.apache.kafka.common.internals.KafkaFutureImpl.access$000(KafkaFutureImpl.java:32)
	at org.apache.kafka.common.internals.KafkaFutureImpl$SingleWaiter.await(KafkaFutureImpl.java:104)
	at org.apache.kafka.common.internals.KafkaFutureImpl.get(KafkaFutureImpl.java:272)
	at org.springframework.kafka.test.EmbeddedKafkaBroker.createTopics(EmbeddedKafkaBroker.java:294)
	... 73 more
Caused by: org.apache.kafka.common.errors.InvalidTopicException: Topic name "${some.topic}" is illegal, it contains a character other than ASCII alphanumerics, '.', '_' and '-'

The test runs again when modifying the build.gradle.kts to use     testImplementation("org.springframework.kafka:spring-kafka-test:2.2.0.M2")

I will look at your code, but we have lots of tests that use placeholders.

Sorry - those tests are in the @KafkaListener; I misread your question; I was not aware we supported placeholders there. Investigating...

So, it doesn't "work" in M2 either; before M3, @EmbeddedKafa only creates a broker when there is a Spring test application available, the context customizer adds the bean to the test context.
In M3, we now allow @EmbeddedKafka to be used as a stand-alone broker, without a Spring test application context (similar to @ClassRule in JUnit4).
With M2, if you change your test to
@EmbeddedKafka(topics = ["\${some.topic}"])
@SpringJUnitConfig
class KafkaTest {
    @Test
    fun `it runs`() {

    }
}

You will see the same failure with M2.
Without the @SpringJUnitConfig, the @EmbeddedKafka is simply ignored.
We could add support for placeholders but only when a Spring test application context is present.
@artembilan WDYT?

We could add support for placeholders but only when a Spring test application context is present.

Isn't that exactly what we have here? If we don't have a Spring Application context around, placeholders are not resolved therefore we fail.
We might need just advertise in the Docs that placeholders in those attributes are going to work only if you use @EmbeddedKafka in the Spring environment.
Am i missing anything?

Right; they won't be resolved when there is no Spring context, but they are currently not resolved when there is a context.

How is that possible?
See EmbeddedKafkaContextCustomizer:
String[] topics =
		Arrays.stream(this.embeddedKafka.topics())
					.map(environment::resolvePlaceholders)
					.toArray(String[]::new);

and KafkaStreamsTests with its:
@RunWith(SpringRunner.class)
@DirtiesContext
@TestPropertySource(properties = "streaming.topic.two=streamingTopic2")
@EmbeddedKafka(partitions = 1,
		topics = {
				KafkaStreamsTests.STREAMING_TOPIC1,
				"${streaming.topic.two}",
				KafkaStreamsTests.FOOS },
		brokerProperties = {
				"auto.create.topics.enable=${topics.autoCreate:false}",
				"delete.topic.enable=${topic.delete:true}" },
		brokerPropertiesLocation = "classpath:/${broker.filename:broker}.properties")
public class KafkaStreamsTests {

Or do you mean it doesn't work with @SpringJUnitConfig?
Don't we still need to add a @TestPropertySource there then?

Not sure, all I can say is the test in my comment above fails with Topic name "${some.topic}" is illegal,.

Not sure, all I can say is the test in my comment above fails with Topic name "${some.topic}" is illegal,.
Shouldn't we fail with a resolution failure if there is no property with that name?

test in my comment above fails with

Doesn't that \$ mean do not treat it as property-placeholder?

Shouldn't we fail with a resolution failure

I think we can't violate here a property-placeholder behavior. If it falls back to the plain value for that syntax, then we should propagate it as is and therefore fail somewhere later.
I mean it works the same way everywhere in Spring, so, why it should not here in Spring Kafka?

The \ is a Kotlin escape.

everywhere in Spring

?
	@KafkaListener(id = "bar", topicPattern = "${topicTwo}")

fails with

Caused by: java.lang.IllegalArgumentException: Could not resolve placeholder 'topicTwo' in value "${topicTwo}"

Who throws that exception?

Caused by: java.lang.IllegalArgumentException: Could not resolve placeholder 'topicTwo' in value "${topicTwo}"
	at org.springframework.util.PropertyPlaceholderHelper.parseStringValue(PropertyPlaceholderHelper.java:178) ~[spring-core-5.2.0.M3.jar:5.2.0.M3]
	at org.springframework.util.PropertyPlaceholderHelper.replacePlaceholders(PropertyPlaceholderHelper.java:124) ~[spring-core-5.2.0.M3.jar:5.2.0.M3]
	at org.springframework.core.env.AbstractPropertyResolver.doResolvePlaceholders(AbstractPropertyResolver.java:237) ~[spring-core-5.2.0.M3.jar:5.2.0.M3]
	at org.springframework.core.env.AbstractPropertyResolver.resolveRequiredPlaceholders(AbstractPropertyResolver.java:211) ~[spring-core-5.2.0.M3.jar:5.2.0.M3]
	at org.springframework.context.support.PropertySourcesPlaceholderConfigurer.lambda$processProperties$0(PropertySourcesPlaceholderConfigurer.java:175) ~[spring-context-5.2.0.M2.jar:5.2.0.M2]
	at org.springframework.beans.factory.support.AbstractBeanFactory.resolveEmbeddedValue(AbstractBeanFactory.java:851) ~[spring-beans-5.2.0.M3.jar:5.2.0.M3]
	at org.springframework.kafka.annotation.KafkaListenerAnnotationBeanPostProcessor.resolve(KafkaListenerAnnotationBeanPostProcessor.java:744) ~[main/:?]

OK. I see:
throw new IllegalArgumentException("Could not resolve placeholder '" +
							placeholder + "'" + " in value \"" + value + "\"");

PropertyPlaceholderHelper.

So, do you mean our logic in the EmbeddedKafkaContextCustomizer is wrong?
May that is what we need to fix...

Anyway it is not going to work when we don't have Spring environment around at all as it is originally reported here.
As you said: it was ignored before without any Kafka in the test.
Now it is going to work without Spring or with Spring when we would like to use property placeholders.
Not sure what else you would like to reconsider here...

And passes unresolved PH unchanged rather than throwing an exception.

Yeah... And why is that I wonder... Sounds like a request for Spring Core?
I can play with that to make it similar what we have with the @KafkaListener

Don't bother; we can document it.
@EmbeddedKafka(topics = ["\${some.topic}"])
@SpringJUnitConfig
@TestPropertySource(properties = ["some.topic=foo"])
class KafkaTest {
    @Test
    fun `it runs`() {

    }
}

works.

Indeed, adding @SpringJUnitConfig works.
However, using the standard @SpringBootTest configuration fails:
@SpringBootTest
@EmbeddedKafka(topics = ["\${some.topic}"])
class KafkaTest {
    @Test
    fun `it runs`() {

    }
}

Is this intended?

It should work as long as the property some.topic is in one of the property sources visible to the test.

Yes, it works when you add some.topic=myTopic to application.properties.

@garyrussell  I tried it exactly like above and when adding the property to application.yaml it still does not work. I also another test to verify the property is resolved.

@artembilan It does understand the yaml extension. This test https://github.com/catchin/spring-embedded-kafka-test/blob/master/src/test/kotlin/com/example/demo/PropertyTest.kt passes.

@garyrussell @artembilan
In my opinion this issue should be reopened.
The test including @SpringBootTest and property in application.yaml fails. See also here: https://travis-ci.org/catchin/spring-embedded-kafka-test

I also tried with application.properties with the same error.
Am 27. Juni 2019 18:39:04 MESZ schrieb Artem Bilan<EMAIL_ADDRESS>
I don't believe that Spring Boot understands yaml extension. It must
be application.yml. Just because you don't show any customization, we
only can assume that there is a default one.
--
You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub:
https://github.com/spring-projects/spring-kafka/issues/1144#issuecomment-506421975

Hm. I see that EmbeddedKafkaContextCustomizer who takes care about property placeholders is invoked only if we have a @SpringJUnitConfig alongside with those @SpringBootTest and @EmbeddedKafka.
Not sure what is wrong just with the @SpringBootTest...

The issue is that the Junit5 EmbeddedKafkaCondition uses the presence of a @SpringJunitConfig annotation to decide whether to create a stand-alone (not Spring) broker...
		if (element.isPresent() &&
				AnnotatedElementUtils.findMergedAnnotation(element.get(), SpringJUnitConfig.class) == null) {

			EmbeddedKafka embedded = AnnotatedElementUtils.findMergedAnnotation(element.get(), EmbeddedKafka.class);
			// When running in a spring test context, the EmbeddedKafkaContextCustomizer will create the broker.
			if (embedded != null) {
				EmbeddedKafkaBroker broker = getBrokerFromStore(context);
				if (broker == null) {
					broker = createBroker(embedded);
					BROKERS.set(broker);
					getStore(context).put(EMBEDDED_BROKER, broker);
				}
			}
		}

We can't test for @SpringBootTest since we can't depend on Boot. So maybe we just document that you must use @SpringJunitCongig ?

(Turns out I was still using M2 when I "thought" it was working).

Well, maybe an @ExtendWith(SpringExtension.class) to check instead?
It is there on @SpringBootTest, too.

Hmmm - yes; that should work.

Trying it now...

@catchin Thanks for your patience and persistence.
This change was needed so we could provide similar capability to JUnit4's @ClassRule.
We appreciate users trying milestones so we catch these kind of issues before the release.
Thanks again.

Thank you as well! I'm glad I could help.


Configure Ceilometer middleware

The Ceilometer middleware sends notifications using RabbitMQ, thus creating a user and secret to configure the middleware.

CI failure seems like it might be legitimate:
logger.go:42: 13:05:02 | basic-deploy_tls/1-deploy-swift | for: "../../../../config/samples/swift_v1beta1_swift_tls.yaml": error when patching "../../../../config/samples/swift_v1beta1_swift_tls.yaml": admission webhook "vswift.kb.io" denied the request: Swift.swift.openstack.org "swift" is forbidden: spec.swiftStorage.replicas: Invalid value: 1: SwiftStorage does not support scale-in

CI failure seems like it might be legitimate:
logger.go:42: 13:05:02 | basic-deploy_tls/1-deploy-swift | for: "../../../../config/samples/swift_v1beta1_swift_tls.yaml": error when patching "../../../../config/samples/swift_v1beta1_swift_tls.yaml": admission webhook "vswift.kb.io" denied the request: Swift.swift.openstack.org "swift" is forbidden: spec.swiftStorage.replicas: Invalid value: 1: SwiftStorage does not support scale-in

Yes, the actual issue was one type - I uppercased the template variable names to make them consistent, but forgot one:
https://github.com/openstack-k8s-operators/swift-operator/compare/7ae67c626d0681e57111857bf9a1b9112ed4dc41..bcae5144e582a49875435da75aef840aeb57ec25

/retest


Switch transaction type by annotation when using Sharding-JDBC with spring

Feature Request
Is your feature request related to a problem?
#986 #1363
Describe the feature you would like.
Currently, Sharding-JDBC switches different types of transactions through TransactionTypeHolder.set method before starting a transaction.
If users use spring-annotated transaction, the switching requires to call the API to set the transaction type before calling the annotated method like this
public void changeTransactionTypeBeforeExecute() {
    TransactionTypeHolder.set(TransactionType.xxx);
    insertData();
}

@Transactional
public void insertData() {
    ......
}

It's seem very inconvenient.
So, I think we can define a new annotation named ShardingTransactional, which extends spring Transactional annotation just like SpringBootApplication annotation. And setting transaction type in AOP interceptor.
Finally, users use this annotation instead of original spring annotation like that
@ShardingTransactional(type="xxx", timeout = 10000, rollbackFor = RuntimeException.class)
public void insertData() {
    ......
}

It looks better.

it is wonderful! consider about add a environment property to distinguish Jdbc and proxy
maybe we can modify transaction type through SET transaction='XX' in proxy.


created a new matcher for numbers

@thomaszurkan-optimizely looks like this is closed. Should we review this?

@nchilada .  Yes please review asap.  I had closed the PR because of the GitHub issues on Friday.

Pull Request Test Coverage Report for Build 725

8 of 8 (100.0%)  changed or added relevant lines in 2 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+0.03%) to 89.29%

Totals

Change from base Build 719:
0.03%

Covered Lines:
2501

Relevant Lines:
2801

💛  - Coveralls


fix cache metrics graphs

Graphs showing currently blank, since metrics had their names changed in
1.7. Fix them, so they'll start showing.
Signed-off-by: Glauber Costa<EMAIL_ADDRESS>

It seems to me I was using a master AMI by accident. Sorry


Messages lacking line breaks

I suspect there are a number of messages like this, that are difficult to read since they are so very, very wide.  It's not highly important but this one I did have to read to the end and it was not fun.

Used Jadeite's String>>skinnyPrintOn: to make the string a bit more readable.

Note - Didn't make the skinny print global for dialog messages (yet).  I still believe that there are dialog warnings and confirmations lurking that have their own formatting which should not be disturbed.


Exclude jsbundle files from VCS

Motivation
jsbundle files can be generated, and are quite large and therefore, I think should be excluded from being committed to the repo.
[ GENERAL ][ MINOR ][local-cli/templates/_gitignore] - Included a new entry to ignore jsbundle files

Can you rebase? A recent internal change is blocking this from landing cleanly.

Thank you for approving the changes. I have rebased the branch as you've requested, I hope this PR has been updated with the changes, and should be ready for merge.

I had no issues doing the rebase. Also, all of the CI checks have passed. I'll now see if any tests can be run manually and report back.

This PR also does not modify any files except for the generated gitignore file. It could be that the internal test depends on the bundle file being checked into the VCS.

The bot took a while to comment, but the failure it mentioned was due to the need to rebase this. I'll re-import.


Missing global variable in saved model when using Lambda layer

Hi,
I'm experiencing an issue when saving a model containing the Lambda layer. I can run the model, compile it, train it, save it. But when I try to load it again, I get an error.
The network does the convolution on each single channel of the image and performs a regression on a final scalar output. To slice the multi-channel tensor I use the Lambda layer, and the index of this layer is causing troubles when saving/loading the model
I attached a full script to replicate the issue. It does not make any sense with the cifar10 dataset, but it's just to replicate the issue! :smile:
import keras
from keras.models import Model
from keras.layers import Dense, Dropout, Activation, Flatten, Input, Concatenate, Lambda
from keras.layers import Conv2D, MaxPooling2D
import os
from keras.callbacks import ModelCheckpoint
import numpy as np

network_name = 'test_this_bug'

np.random.seed(10)

batch_size = 100
num_classes = 10
epochs = 10

(x_train, y_train),(x_test, y_test) = keras.datasets.cifar10.load_data()
Nchannels = x_train.shape[3]
img_rows = x_train.shape[1]
img_cols = x_train.shape[2]

#x_train = np.moveaxis(x_train,1,3)
#x_test = np.moveaxis(x_test,1,3)

main_input = Input(shape=(img_rows,img_cols,Nchannels))
channels = []
for i in range(Nchannels):
    # Slice the tensor getting the i-th channel
    x = Lambda(lambda x: x[:,:,:,i,None])(main_input)
    x = Conv2D(4, kernel_size=(3,3), strides=(2,2))(x)
    x = Activation('relu')(x)
    x = MaxPooling2D(pool_size=(2,2), strides=(2,2))(x)

    x = Conv2D(8, kernel_size=(3,3), strides=(2,2))(x)
    x = Activation('relu')(x)
    x = MaxPooling2D(pool_size=(2,2), strides=(2,2))(x)

    x = Dropout(0.1)(x)

    x = Flatten()(x)
    channels.append(x)

channels = Concatenate()(channels)
channels = Dense(128)(channels)
channels = Activation('relu')(channels)
channels = Dropout(0.2)(channels)

main_output = Dense(1)(channels)
main_output = Activation('relu')(main_output)

model = Model(inputs=main_input, outputs=main_output)

model.summary()

opt = keras.optimizers.RMSprop()

model.compile(optimizer=opt, loss='mean_squared_error', metrics=['accuracy'])

x_train = x_train.astype('float32')/255;
x_test = x_test.astype('float32')/255;

best_model_name = '%s_best.h5' % network_name

# Callbacks
filepath = os.path.join(os.getcwd(),best_model_name)
checkpoint = ModelCheckpoint(filepath, monitor='val_loss', verbose=1,
                                 save_best_only=True,period=2)

callbacks = [checkpoint]

model.fit(x_train,y_train,
         batch_size=batch_size,
         epochs=epochs,
         validation_data=(x_test,y_test),
         callbacks=callbacks)

After the script has finished, I simply open ipython and run:
import keras
import os
model = keras.models.load_model(os.path.join(os.getcwd(),'test_this_bug_best.h5'))

The result is this long error, referring to the variable i of the Lambda layer:
In [5]: model = keras.models.load_model(os.path.join(os.getcwd(),'test_this_bug_best.h5'))
---------------------------------------------------------------------------
NameError                                 Traceback (most recent call last)
<ipython-input-5-37356b91a563> in <module>()
----> 1 model = keras.models.load_model(os.path.join(os.getcwd(),'test_this_bug_best.h5'))

/mnt/storage/home/username/.local/lib/python2.7/site-packages/keras/models.pyc in load_model(filepath, custom_objects, compile)
    241             raise ValueError('No model found in config file.')
    242         model_config = json.loads(model_config.decode('utf-8'))
--> 243         model = model_from_config(model_config, custom_objects=custom_objects)
    244
    245         # set weights

/mnt/storage/home/username/.local/lib/python2.7/site-packages/keras/models.pyc in model_from_config(config, custom_objects)
    315                         'Maybe you meant to use '
    316                         '`Sequential.from_config(config)`?')
--> 317     return layer_module.deserialize(config, custom_objects=custom_objects)
    318
    319

/mnt/storage/home/username/.local/lib/python2.7/site-packages/keras/layers/__init__.pyc in deserialize(config, custom_objects)
     53                                     module_objects=globs,
     54                                     custom_objects=custom_objects,
---> 55                                     printable_module_name='layer')

/mnt/storage/home/username/.local/lib/python2.7/site-packages/keras/utils/generic_utils.pyc in deserialize_keras_object(identifier, module_objects, custom_objects, printable_module_name)
    142                 return cls.from_config(config['config'],
    143                                        custom_objects=dict(list(_GLOBAL_CUSTOM_OBJECTS.items()) +
--> 144                                                            list(custom_objects.items())))
    145             with CustomObjectScope(custom_objects):
    146                 return cls.from_config(config['config'])

/mnt/storage/home/username/.local/lib/python2.7/site-packages/keras/engine/topology.pyc in from_config(cls, config, custom_objects)
   2518                 if layer in unprocessed_nodes:
   2519                     for node_data in unprocessed_nodes.pop(layer):
-> 2520                         process_node(layer, node_data)
   2521
   2522         name = config.get('name')

/mnt/storage/home/username/.local/lib/python2.7/site-packages/keras/engine/topology.pyc in process_node(layer, node_data)
   2475             if input_tensors:
   2476                 if len(input_tensors) == 1:
-> 2477                     layer(input_tensors[0], **kwargs)
   2478                 else:
   2479                     layer(input_tensors, **kwargs)

/mnt/storage/home/username/.local/lib/python2.7/site-packages/keras/engine/topology.pyc in __call__(self, inputs, **kwargs)
    615
    616             # Actually call the layer, collecting output(s), mask(s), and shape(s).
--> 617             output = self.call(inputs, **kwargs)
    618             output_mask = self.compute_mask(inputs, previous_mask)
    619

/mnt/storage/home/username/.local/lib/python2.7/site-packages/keras/layers/core.pyc in call(self, inputs, mask)
    661         if has_arg(self.function, 'mask'):
    662             arguments['mask'] = mask
--> 663         return self.function(inputs, **arguments)
    664
    665     def compute_mask(self, inputs, mask=None):

/mnt/storage/home/username/.local/lib/python2.7/site-packages/keras/layers/core.pyc in <lambda>(x)
     27 for i in range(Nchannels):
     28     # Slice the tensor getting the i-th channel
---> 29     x = Lambda(lambda x: x[:,:,:,i,None])(main_input)
     30     x = Conv2D(4, kernel_size=(3,3), strides=(2,2))(x)
     31     x = Activation('relu')(x)

NameError: global name 'i' is not defined

In [6]: model = keras.models.load_model(os.path.join(os.getcwd(),'test_this_bug_best.h5'))

Some additional info:

Using a cluster
Running Keras 2.1.4 on Python 2.7.12
Using TensorFlow 1.2.0 with a Tesla P100-PCIE-16GB
OS: CentOS Linux release 7.3.1611
Kernel: Linux  3.10.0-514.10.2.el7.x86_64

Please make sure that the boxes below are checked before you submit your issue. If your issue is an implementation question, please ask your question on StackOverflow or join the Keras Slack channel and ask there instead of filing a GitHub issue.
Thank you!

[x] Check that you are up-to-date with the master branch of Keras. You can update with:
pip install git+git://github.com/keras-team/keras.git --upgrade --no-deps

[x] If running on TensorFlow, check that you are up-to-date with the latest version. The installation instructions can be found here.

[x] If running on Theano, check that you are up-to-date with the master branch of Theano. You can update with:
pip install git+git://github.com/Theano/Theano.git --upgrade --no-deps

[x] Provide a link to a GitHub Gist of a Python script that can reproduce your issue (or just copy the script here if it is short).

Same issue with me

same here. This is a more simple example:
import numpy as np

from keras.models import load_model
from keras.models import Model
from keras.layers import Input, Lambda
from keras import backend as K

rep = 2
inp = Input([1])
out = Lambda(lambda x: K.repeat_elements(K.expand_dims(x, 1), rep, 1))(inp)
model = Model(inp, out)
X = np.array([[1], [2]])
print('results', model.predict(X))

model.save('test.h5')
del model

model = load_model('test.h5')
print('results', model.predict(X))

I see this (with some anonymization):
results [[[1.]
  [1.]]]

---------------------------------------------------------------------------
NameError                                 Traceback (most recent call last)
<ipython-input-19-23a1dbe4ad39> in <module>()
     16 del model
     17
---> 18 model = load_model('test.h5')
     19 print('results', model.predict(X))

/.../python3.6/site-packages/keras/engine/saving.py in load_model(filepath, custom_objects, compile)
    258             raise ValueError('No model found in config file.')
    259         model_config = json.loads(model_config.decode('utf-8'))
--> 260         model = model_from_config(model_config, custom_objects=custom_objects)
    261
    262         # set weights

/.../lib/python3.6/site-packages/keras/engine/saving.py in model_from_config(config, custom_objects)
    332                         '`Sequential.from_config(config)`?')
    333     from ..layers import deserialize
--> 334     return deserialize(config, custom_objects=custom_objects)
    335
    336

/.../lib/python3.6/site-packages/keras/layers/__init__.py in deserialize(config, custom_objects)
     53                                     module_objects=globs,
     54                                     custom_objects=custom_objects,
---> 55                                     printable_module_name='layer')

/.../lib/python3.6/site-packages/keras/utils/generic_utils.py in deserialize_keras_object(identifier, module_objects, custom_objects, printable_module_name)
    143                     config['config'],
    144                     custom_objects=dict(list(_GLOBAL_CUSTOM_OBJECTS.items()) +
--> 145                                         list(custom_objects.items())))
    146             with CustomObjectScope(custom_objects):
    147                 return cls.from_config(config['config'])

/.../lib/python3.6/site-packages/keras/engine/network.py in from_config(cls, config, custom_objects)
   1025                 if layer in unprocessed_nodes:
   1026                     for node_data in unprocessed_nodes.pop(layer):
-> 1027                         process_node(layer, node_data)
   1028
   1029         name = config.get('name')

/.../lib/python3.6/site-packages/keras/engine/network.py in process_node(layer, node_data)
    984             # and building the layer if needed.
    985             if input_tensors:
--> 986                 layer(unpack_singleton(input_tensors), **kwargs)
    987
    988         def process_layer(layer_data):

/.../lib/python3.6/site-packages/keras/engine/base_layer.py in __call__(self, inputs, **kwargs)
    455             # Actually call the layer,
    456             # collecting output(s), mask(s), and shape(s).
--> 457             output = self.call(inputs, **kwargs)
    458             output_mask = self.compute_mask(inputs, previous_mask)
    459

/.../lib/python3.6/site-packages/keras/layers/core.py in call(self, inputs, mask)
    680         if has_arg(self.function, 'mask'):
    681             arguments['mask'] = mask
--> 682         return self.function(inputs, **arguments)
    683
    684     def compute_mask(self, inputs, mask=None):

/.../lib/python3.6/site-packages/keras/layers/core.py in <lambda>(x)
      8 rep = 2
      9 inp = Input([1])
---> 10 out = Lambda(lambda x: K.repeat_elements(K.expand_dims(x, 1), rep, 1))(inp)
     11 model = Model(inp, out)
     12 X = np.array([[1]])

NameError: name 'rep' is not defined

I guess my PR on Tensorflow hasn't been merged to keras.
https://github.com/tensorflow/tensorflow/pull/18926
I'll resubmit it here.

I came up with a silly fix for now. Basically, using the global variables as values for arbitrary arguments solved the scope issue:
def my_lambda(x, gvar1=gvar1, ...):
    return ...

out = Lambda(my_lambda)(inp)


[HOLD for payment 2022-07-15] [$250] Password Field should not Autofill with the old password on the Set Password page - reported by @parasharrajat

If you haven’t already, check out our contributing guidelines for onboarding and email<EMAIL_ADDRESS>to request to join our Slack channel!

Action Performed:

Go the login page.
Enter an email. Press Enter.
Click forget on the password page.
Check the mailbox and Copy the link.
open the link on the browser

Expected Result:
Check that if you had saved the password earlier for the email, password field is autofilled.
Actual Result:
It should not autofill with old password as user is expected to enter new password.
Workaround:
unknown
Platform:

Where is this issue occurring?

Web

Version Number: 1.1.69-0
Reproducible in staging?: Y
Reproducible in production?: Y
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation

Expensify/Expensify Issue URL:
Issue reported by: @parasharrajat
Slack conversation: https://expensify.slack.com/archives/C01GTK53T8Q/p1651158076558069
View all open jobs on GitHub

It looks like there's this autocomplete="new-password" we could add to the password field when they're setting a new password. Seems like that would be helpful!

Proposal
As suggested by @conorpendergrast, we need to set autoComplete to new-password for the specific text input.
The following changes:
https://github.com/allroundexperts/Expensify/blob/0f38b9a0107977e2b49edef1534caf1199e08b38/src/pages/settings/NewPasswordForm.js#L71
To:
               <TextInput
                    autoComplete="new-password"

###Proposal
Problem
We're nor passing any prop to decide the behaviour of auto complete in the input field
Solution
We should pass a prop autoCompleteType="new-password" for web and autoCompleteType="password-new"
new-password does not work for native
we will pass the new value here
https://github.com/Expensify/App/blob/dc300ee45cde0124f6223f715a526c0f50ef2dcc/src/pages/settings/NewPasswordForm.js#L74

@allroundexperts @Harshdeepjoshi I'm really confused here.
autoComplete="new-password" works on web only.
autoComplete="password-new" works for Android only. (React native docs)
So.. what should we do here to fix this issue for web, iOS and Android?

@allroundexperts yes it was a typing mistake

@allroundexperts @Harshdeepjoshi I'm really confused here.
autoComplete="new-password" works on web only. autoComplete="password-new" works for Android only. (React native docs)
So.. what should we do here to fix this issue for web, iOS and Android?
(@Harshdeepjoshi im sure you mean autoComplete and not autoCompleteType)

@rushatgabhane We can do a quick platform check to determine that.

@rushatgabhane Updated my proposal to handle this.

@rushatgabhane we can pass textContentType to newPassword

@allroundexperts it's highly recommended to post updated proposals as a new comment.
And we use platform specific extensions over in-line platform code.
@Harshdeepjoshi yeah, that could work! Please post an updated proposal, thank you!

@rushatgabhane Apologies. Mine updated proposal is same as that of @Harshdeepjoshi.

@allroundexperts no worries :)

@rushatgabhane please check my updated proposal, I have added the necessary changes.

@rushatgabhane . Do you need anything else from me? I am new so any instructions would be helpful. Thank you.

@Harshdeepjoshi just one question - which autofill service have you used to verify your proposal?

I used the browser autofill on firefox (No external password managers).

@rushatgabhane I tested it on firefox and chrome.

@Julesssss thoughts on this proposal

Sorry, missed this one. Approving @Harshdeepjoshi's proposal 👍

@Harshdeepjoshi have you applied? I'd like to hire you!

Whoops, I see the PR now

Nice work on your first PR @Harshdeepjoshi! It has been merged, we now need to wait for it to be deployed. 7 days after that you should be paid

not overdue - waiting for it to be deployed

Can be paid today

Paid! @parasharrajat I missed hiring you for the reporting bonus, will you apply here

@adelekennedy Please check I have already applied.

hired!

Thanks, there is also reporting bonus for this one :smiley:

@parasharrajat to confirm are you eligible for more than the reporting bonus? I see that @rushatgabhane was assigned as the C+ and @Harshdeepjoshi was assigned as the contributor, am I missing something? Please let me know 😄

oh, my bad. I confused this with someone else. So just for the reporting.

Perfect - and no worries, you're juggling a ton of issues!


Feature request - homebrew package

I've only been using NanoVG for about a week and I think it's awesome! Installing the library is easy but it's not as easy as letting a package manager install the library for me. If this library is no-longer being updated then there would be little benefit in creating a homebrew package because the user would only need to install the library once. Of course, this is your decision. I just think creating a homebrew package would be more convenient for the user.

I wrote a first draft of a libnanovg Homebrew formula. It seems to work quite well so far.
You can try it out by downloading the file, cding to the folder, and then running:
brew install --HEAD libnanovg.rb

Before we can submit the formula to Homebrew, there are a few minor issues left to fix in nanovg:

[ ] Merge #419 (unless there is a good reason to stick with glfw3 for the Mac build)

[ ] Consider adding a shared library build (this is optional; my formula supports this by patching premake4.lua but that patch needs to go before submitting to Homebrew)

[ ] Create a release tag, e. g. v0.1

@memononen I understand there is little incentive for you to add Homebrew support. I feel that Mac users are going to find the formula very convenient. Apart from the necessary up-front fixes listed above, a Homebrew formula will not cause the project any maintenance burden. It’s Homebrew contributors who are responsible for maintaining the formula, not you as the upstream project maintainer.

@claui thanks for taking the time to make this too easy for me :)
The library is intended to be included as source, so no shared library.
NanoVG itself does not need GLFW, but the examples need it. How does homebrew deal with libraries which have kind of the "library" part and demos in it?
I'm fine with the glfw3 vs glfw thing as long as I can make it work on my machine. I'm still hesitant to use homebrew. I have previously had annoying problems using it. I think the problem case was if I had to manually install something which was also available at homebrew, so things just got messed up big time. Maybe I could give it another go.

NanoVG itself does not need GLFW, but the examples need it. How does homebrew deal with libraries which have kind of the "library" part and demos in it?

By default, glfw is installed and the examples are built. If the --without-examples option is present, glfw is not installed and the examples are not built. Homebrew itself doesn't specifically handle libraries with examples in them. Formulae can just choose to build the examples if they want to. Specifically, the formula installs the examples in the libexec directory of the keg.

@memononen What @Kerndog73 says is 100 % correct. In case you’re interested in a few more details:
Homebrew uses package-specific directories to install packages, e. g. /usr/local/Cellar/libnanovg/0.1 for nanovg.
As to organizing libs vs. examples, Homebrew provides standards for this. According to my formula (which aims to stick to those standards), Homebrew will install nanovg as follows:
/usr/local/Cellar/libnanovg/0.1/
    bin/
        example_fbo       ← Bash shims for libexec/bin/…
        …                 ← (nanovg-specific workaround; needed
                          ← because binaries rely on the cwd)

    include/
        nanovg.h
        …

    lib/
        libnanovg.a
        libnanovg.dylib

    libexec/
        bin/
            example_fbo   ← binaries
            …
        example/          ← example code; runtime resources
            …             ← (basically a copy of `example`)

    share/doc/libnanovg/
        LICENSE.txt
        README.md

As a post-install step, Homebrew will then create appropriate symlinks:
/usr/local/Cellar/libnanovg/0.1/
    bin/
        example_fbo       ← /usr/local/bin/example_fbo
        …                   …

    include/
        nanovg.h          ← /usr/local/include/nanovg.h
        …

    lib/
        libnanovg.a       ← /usr/local/lib/libnanovg.a
        libnanovg.dylib   ← …

    libexec/              ← By convention, Homebrew will not
        bin/                create symlinks to any of these.
            example_fbo
            …
        example/
            …

    share/doc/libnanovg/  ← /usr/local/share/doc/libnanovg/
        LICENSE.txt
        README.md

The library is intended to be included as source

@memononen By as source, are you referring to e. g. nanovg.c? Where exactly would you want the source file included?

so no shared library

That’s fine. I was suggesting a dylib option mainly because I’ve seen instances of nanovg used as a dylib in the wild. Of course I respect your choice to not offer a shared library build.
Just to understand your words 100 % correctly: you are not willing to accept a PR based on this patch, correct? (Just asking because I’ve been preparing that exact PR.)