[Feature Request] Implicit numeric tower option in beartype.BeartypeConf

Discussed in https://github.com/beartype/beartype/discussions/173

Originally posted by felixchenier September 26, 2022
Good morning
I'm trying to see if beartype would fit my need as a simple-to-operate real-time type checker. This is for a public API that I'm building, and I don't want to manually check everything, or to reprogram something that is for sure a very deep rabbit hole!
But I have an issue with beartype being a little bit too rigorous. Many of my functions accept floats as parameters, and I expect the users (including me) to sometimes provide integers instead of floats. The calculations work, and mypy is also fine with it. However, by using beartype, I have a runtime error (int != float), which in my case is not what I would need.
I don't want to mess with every signature and change (a: float) to (a: Union[float, int]), which:

is ugly and useless;
will fail eventually, since I will forget one, mypy won't tell me, but I'll have plenty of users who will have unexpected runtime errors.

Is there an easy way to switch off some type checks, such as this one?
Thank you!

...heh. This is a classic conundrum.
By default, @beartype intentionally rejects lossy coercions – because they're lossy. In most mission-critical fields (like finance or biotech, the latter of which my wife and I work in), lossy coercions are often outright prohibited by binding contracts, internal policies, and/or governmental regulations; in less mission-critical fields, lossy coercions are still typically seen as undesirable. Since @beartype is oriented towards scientific applications, a loss of numerical precision without the explicit consent of the developer is generally bad and not something we want actively encourage or promote...
By default, anyway! Thankfully, @beartype fully supports Python's explicit tower. Admittedly, you probably don't want to. This is a laborious refactoring that would you require you to explicitly retype all type hints across your public API from float to numeric.Real: e.g.,
# Consider globally replacing all uses of "float" in annotations like this...
@beartype
def crunch_numbers(numbers: list[float]) -> float:
    return sum(numbers)

# ...with uses of "numeric.Real", instead. @beartype already supports this
# out-of-the-box. Rejoice! \o/
from numeric import Real

@beartype
def crunch_numbers(numbers: list[Real]) -> Real:
    return sum(numbers)

You are now thinking: "I hate @beartype." I knew it. You were thinking that.
But that's fine. You're not wrong to want the implicit numeric tower. You're right, actually. We really should support that with a new option. I believe we can eventually satisfy everyone, because @beartype's three middle names are Mr. Happy Bear.
But first: a Mostly Meaningless Monologue to Myself (MMMtM) on PEP 484. :grimacing:
B-b-ut... PEP 484!
So. It comes to this.
There's a conflict here between PEP 8's maxim that "Explicit is better than implicit" and PEP 484's implicit numeric tower. Whenever something conflicts with PEP 8, @beartype usually errs on the side of PEP 8. PEP 8 is the bible we all code by, after all. We believe Guido, Jukka Lehtosalo, and Łukasz Langa got that subsection of PEP 484 profoundly wrong. They meant well, but that's how the road to unpleasant places is paved. That said...
Options Are Fun for the Whole Family
@beartype really should provide an option to enable the implicit numeric tower. If you have this pressing API need without which @beartype is uselessly dead to you, then so does everybody else, @felixchenier.
Fortunately, @beartype has an existing public configuration API. We could certainly add a new public boolean to that API instructing @beartype to respect implicit number coercions (e.g., complex -> float -> int). I'm kinda at a loss of what to name that boolean, but I'm sure we can hack out something reasonably disambiguous. Possibilities include:

is_implicit_numeric_tower? is_allow_numeric_coercion? Painfully long, but painfully clear.
is_coerce_numbers? Blessedly shorter... and still mostly blessedly clear.
is_numeric_tower? Even shorter, but now we're trending towards ambiguity.

Anyway! Let's assume is_coerce_numbers for sanity. Here's how you'd actually use it:
from beartype import beartype, BeartypeConf

beartype_towering = beartype(conf=BeartypeConf(is_coerce_numbers=True))
'''
:func:`beartype.beartype` decorator configured to enable the
:pep:`484`-compliant **implicit numeric tower** (i.e., allow lossy coercions
from `complex` to `float` to `int` types).
'''

@beartype_towering
def crunch_numbers(numbers: list[float]) -> float:
    return sum(numbers)

# This is now fine.
crunch_numbers([3, 1, 4, 1, 5, 9])

# This is still fine, too.
crunch_numbers([3.1, 4.1, 5.9])

Best of both worlds right there, right? Your public API preserves its current annotations and mypy-compliance. Meanwhile, you just decorate classes and callables with your API-specific @beartype_towering decorator that nobody else needs to know about.
Would that satisfy everything on your end?
The Road to Heaven Is Paved with Good Commits
Might I say, too, that I love hearing from fellow Canucks. My wife and I had a dusty road trip across the Quebec wilderness a few years back. Francophones everywhere are a wonderfully hospitable people. The l'Acropole des Draveurs in the Montagne des Érables is not a thing we will ever forget, either.
Thanks so much for the thoughtful feature request, @felixchenier. We promise to satisfy your API's urgent need for the implicit numeric tower as soon as our Bengal cat stops angrily squealing for food. Gah! Down, feisty cat with wickedly blood-sharp claws! Down! :tiger: :tiger2:

If there was a beartype.check_argument_types() function, that would be insanely great.

Bwaha! My documentation must be even worse than I thought. Okay, my documentation absolutely is worse than I thought – because @beartype does provide a growing laundry list of statement-level near-real-time runtime type-checkers that guarantee O(1) time complexity with negligible constants.  Rejoice, gentlemen! :partying_face:
You have a menu of four options here, depending on whether you prefer a procedural or object-oriented API and whether you prefer your check to raise an exception or just return True or False:
# Import the requisite machinery.
>>> from beartype.door import TypeHint, die_if_unbearable, is_bearable

# Procedurally return "True" only if an object satisfies a hint.
>>> is_bearable('Stop exploding, you cowards.', list | bool | None)
False
>>> is_bearable('Stop exploding, you cowards.', list | bool | None | str)
True

# Object-orientedly do the same thing if you prefer your APIs hard-boiled.
>>> TypeHint(list | bool | None).is_bearable('Stop exploding, you cowards.')
False

# Procedurally raise an exception if an object violates a hint.
>>> die_if_unbearable("My people ate them all!", list | int | None)
BeartypeDoorHintViolation: Object 'My people ate them all!' violates
type hint list | int | None, as str 'My people ate them all!' not
<class "builtins.NoneType">, list, or int.
>>> die_if_unbearable("My people ate them all!", list | int | None | str)
# <-- silence is golden

# Object-orientedly do the same thing if that's just how you roll.
>>> TypeHint(list | int | None | str).die_if_unbearable('My people ate them all!')
False

They're not quite as automated as typeguard's check_argument_types() and check_return_type() utilities, which automatically check against the type hints annotating the current function. But those utilities fail for closures and nested callables. So, that's probably just as well.
Also, everything above runs in around 1µs (i.e., one millionth of a second) regardless of input size. You know. Just sayin'.
Also...

But they often add so many frames to the traceback, that it significantly negatively affects debugging.

This must be your lucky Wednesday. @beartype-decorated callables add absolutely no additional frames to the traceback (except for a single extra frame that performs the actual type-check, of course). The proof is in the dairy-free pudding. Behold!
>>> from beartype import beartype
>>> @beartype
... def omg(wtf: str) -> int:
...     return len(wtf)
>>> omg(b"I can't believe it's a byte-string.")
Traceback (most recent call last):
  Input In [28] in <cell line: 1>
    omg(b"I can't believe it's a byte-string.")
  File <@beartype(__main__.omg) at 0x7f57a9abfbe0>:21 in omg
BeartypeCallHintParamViolation: @beartyped __main__.omg()
parameter wtf=b"I can't believe it's a byte-string." violates type hint
<class 'str'>, as bytes b"I can't believe it's a byte-string." not instance of str.

Note the complete lack of any stack frames in that traceback.
Just like you, everyone wanted that. Everyone hates traceback frames, too. Everyone was right. So we deeply refactored @beartype to ensure that a few releases ago. These must be the glory days of typing, indeed.

What? I violated something? What's been violated, is it okay? I hope so much I didn't break something. What is a type hint? What is an instance? What is that bear that violates types? I quit.

:laughing:
Oh, man. You got me.  I'm rolling in my seat over here and the cat's looking at me funny... yet again.
You're right, of course. @beartype is excrutiatingly exact to the point of gross stupidity and negligence.  Just kidding, of course. We all love @agronholm here and just wish he had a bit more time to throw at typeguard.
So, colouring helps @beartype readability a bit. But... yeah. We can and really should do better there. Let's consider what can be done while I pet our purring Bengal cat like a real Canadian Prime Minister.

Wow, that's pure magic. Sorry for not reading the doc well, the thing is that I'm not formed in computer science. I mostly learned by myself, and there are lots of concepts that I know for sure, but not to the point where I could put a name on it. Since the doc has lots of CS jargon, then I'm often a bit lost in it. But than you @leycec for your examples in this reply, I see more and more how I could use beartype. I added a question here: #176 about numpy ArrayLike. If we can get ArrayLike and implicit numeric tower to work, then I'm pretty sure beartype will become a solid addition to my toolkit. In the mean time, I programmed a lousy, deficient, ugly, slow, shaky, short-sighted and bald type checker for my temporary needs, so I'm not in a rush.

Oh, no worries whatsoever! My wife's entirely self-taught, too – which is probably why she codes circles around me like a software tyrant while I'm mostly just fiddling with type-checking here in the back corner. The self-taught are often the best. Take it from most well-known musicians, for example; they can't read sheet music and never went to Conservatory, but we all know their names. You're kinda like that. :full_moon_with_face:
I'm currently obsessed with documenting everything we pushed out for beartype 0.11.0. So, it may take a hot minute or two for me to finally implement this feature request for the implicit numeric tower. On the bright side, when I finally do, it should be pretty trivial. Let's choose to believe these seductive words I am saying.

It's happening. I... decided against documentation, because documentation is boring. Instead, we're going hard on our configuration API for @beartype's upcoming 0.12.x release cycle. That means this is up next. The tension is palpable.
Rejoice, @felixchenier! @beartype is almost usable for your use case now. :grin:

It happened! Although difficult to believe, I did something and even documented it:
# Import the requisite machinery.
from beartype import beartype, BeartypeConf

# Dynamically create a new @beartowertype decorator enabling the tower.
beartowertype = beartype(conf=BeartypeConf(is_pep484_tower=False))

# Decorate with this decorator instead of the vanilla @beartype decorator.
@beartowertype
def crunch_numbers(numbers: list[float]) -> float:
    return sum(numbers)

# This is now fine.
crunch_numbers([3, 1, 4, 1, 5, 9])

# This is still fine, too.
crunch_numbers([3.1, 4.1, 5.9])

We'll be publishing this in our upcoming beartype 0.12.0 release this Friday. I think that only leaves numpy.typing.ArrayLike and numpy.typing.DTypeLike as your final concerns, right?
Sadly, I am tired. The mind is willing; the flesh is weak. Would you mind if I take a rain check on those two for a bit?  With any luck (and no small amount of prodding), we'll tackle both in beartype 0.13.0.
Thanks again for all the interest and being such an awesome Québécois! Please gently prod me in a discussion or issue if I stay tired and fail to do anything about numpy.typing. Until then, may the spooky maple leaves of Halloween be with us all. :maple_leaf: :jack_o_lantern: :maple_leaf:


added green success colour on form submit

👷 Deploy Preview for cg-eleventy-blog processing.

Name
Link

🔨 Latest commit
34df7459eb0a85f9e4bfd0164b63bcf7e5dd1d8c

🔍 Latest deploy log
https://app.netlify.com/sites/cg-eleventy-blog/deploys/65c44fddf84d6c0007496492


Compiling SPDM with KLEE toolchain with concrete value of "spdm_context"

We were trying to get SPDM (commit 8b7140dbc632bae82b216aa8a00fd17c43c13247) built with KLEE toolchain. The goal is to start with some concrete input and gradually move towards symbolic. Instead of passing the unit test generated by cmocka, we tried to construct  a concrete input for spdm_context in https://github.com/DMTF/libspdm/blob/main/unit_test/test_spdm_requester/get_version.c
spdm_context = {version, p1 ( NULL, 0, NULL, 0),  p2 ( NULL, NULL, NULL, 0 ),  p3 ( NULL, NULL, false, false, 0, NULL,  NULL, NULL ) , p4 ( NULL, &NULL, &false, false, 0, NULL,  NULL, NULL ) , error_state,  {last_spdm_request[0]}, last_spdm_request_size, last_spdm_request_session_id, last_spdm_request_session_id_valid, last_spdm_error, get_response_func, get_encap_response_func, encap_context, spdm_session_state_callback, spdm_connection_state_callback, local_context, connection_info, transcript, session_info, latest_session_id, response_state, error_data, cache_spdm_request, cache_spdm_request_size, current_token, retry_times, crypto_request, app_context_data_ptr, last_update_request, request_response, handle_error_return_policy };      status = libspdm_get_version(spdm_context, NULL, NULL);     assert_int_equal(status, RETURN_DEVICE_ERROR);
and got the following error while building spdm:
libspdm/unit_test/test_spdm_requester/get_version.c:1051:16: error: expected expression
spdm_context = {version, p1 ( NULL, 0, NULL, 0),  p2 ( NULL, NULL, NULL, 0 ),  p3 ( NULL, NULL, false, false, 0, NULL,  NULL, NULL ) , p4 ( NULL, &NULL, &false, false, 0, NULL,  NULL, NULL ) , error_state,  {last_spdm_request[0]}, last_spdm_request_size, last_spdm_request_session_id, last_spdm_request_session_id_valid, last_spdm_error, get_response_func, get_encap_response_func, encap_context, spdm_session_state_callback, spdm_connection_state_callback, local_context, connection_info, transcript, session_info, latest_session_id, response_state, error_data, cache_spdm_request, cache_spdm_request_size, current_token, retry_times, crypto_request, app_context_data_ptr, last_update_request, request_response, handle_error_return_policy };
Maybe we are passing the inputs wrong. Could you please provide any suggestion on how we should be constructing valid inputs for spdm_context?

First, glad to hear you are using KLEE.
Second, sorry, KLEE work was done long time ago, but it is out of maintenance for a long time. Especially, we have added lots of new features/code.
You may try https://github.com/DMTF/libspdm/blob/main/unit_test/fuzzing/test_requester/test_spdm_requester_get_version/get_version.c, but I do not provide any guarantee.
Instead of using existing test code, I recommend you write small code at first to test a specific function.

@TR174 We will close this issue for now. Please file a new issue if you need further help.


Additional flags to bump major/minor/patch parts

This PR adds the new flags -next-major, -next-minor and -next-patch to increment major/minor/patch parts of the version respectively.
Usage example:
$ git-semver
v6.0.1
$ git-semver -next-major
v7.0.0
$ git-semver -next-minor
v6.1.0
$ git-semver -next-patch
v6.0.2

Will update the documentation and add missing tests if you are fine with this implementation and idea.

Why did you close this PR @kostiantyn-nemchenko ? I'm interested in this feature.


[patch] 0.9.5

A landing page for the stack of PRs for the next patch bump. All have tests passing on my local machine, but are waiting for a new version of pyiron_base which allows the most-recent version of pyiron_snippets. In the meantime, I want to merge down the stack for some sanity.

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

0 of 0   changed or added relevant lines in 0 files are covered.
30 unchanged lines in 2 files lost coverage.
Overall coverage increased (+0.04%) to 92.47%

Files with Coverage Reduction
New Missed Lines
%

node.py
13
93.75%

mixin/storage.py
17
92.92%

Totals

Change from base Build<PHONE_NUMBER>1:
0.04%

Covered Lines:
3291

Relevant Lines:
3559

💛  - Coveralls


Add executable bit to get_models.sh

All of the other scripts have the executable bit set, so.

Bump


Memory access out of bounds

hey I was trying to use webpack to bundle meshjs and use it so it can be imported into an html page, the browser wallet object is imported fine and I can connect to different wallets, but when I try to build a transaction I get the error RuntimeError: memory access out of bounds

I was running a simple express server and rendering the html on that for testing

Not sure if this is the same issue I encountered - but I found this error occur when you pass the quantity as an integer rather than a string. It needs to be a string (of the number)

Not sure if this is the same issue I encountered - but I found this error occur when you pass the quantity as an integer rather than a string. It needs to be a string (of the number)

@gammahazard this could be the case, in order to prevent rounding errors, we made a design choice to use strings for numbers. Quantity needs to be strings.


Cleanup Consumption and handle idempotency

Issue/Task Number: T293
Overview
It seems some of the logic to handle max_consumptions_per_user were lost after a night without sleep. This PR adds the missing bit that should fix everything.


Update xamarin-impl service connection

Update service connection for the xamarin-impl public feed access.

The VSEngSS-MicroBuild2022-1ES pool needs an update to include AzureCLI before this can be merged.


Handle cloud errors better

When running in a simulator, cloud backup starts but doesn't complete if a user is not logged in with an apple id.
this causes a new wallet to stay stuck on generating keys message and doesn't move to the home screen.
This can be handled better to ensure that cloud issues don't cause users to get stuck on the initialisation bottom loader message.

@AliMeer, Need to test this ticket when not logged in with an apple id. I'm unable to verify on BrowserStack as the iOS setting won't launch.

-Verified this issue on dev app v1.7.5(299)


Windows support

Would be great to get this working on windows:
E:\repos\aragon\hack\website\node_modules\solidity-docgen\lib\index.js:134
    throw new Error(['Command line operation failed with code ' + commandOutput.code + '.', 'Standard error output: ' + commandOutput.stderr].join('\n'));
    ^

Error: Command line operation failed with code 1.
Standard error output: unrecognised option '-type'

The problematic line is: https://github.com/OpenZeppelin/solidity-docgen/blob/fc57890ff58ac434ddc6d5f54ab879c3b593772a/src/index.js#L113

Hey there. We've stopped maintaining v0.1 of solidity-docgen. Please check out #23 to learn about v0.2. It was a rewrite and find is not used anymore. If anyone finds issues on Windows please open a new issue.


Beneficiary typeahead setting

Allow users to change whether their organisation can show beneficiary typeaheads or not.
This should be in the settings page under organisation.

 Beneficiary Typeahead


convos: fix tests

Patch for time() dependent test started to fail after<PHONE_NUMBER>.
Patch for disk space test that fails on zfs.

Things done

[ ] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
Built on platform(s)

[X] NixOS
[ ] macOS
[ ] other Linux distributions

[X] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[X] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Ensured that relevant documentation is up to date
[ ] Fits CONTRIBUTING.md.

nix-review build fails with:
#   Failed test 'similar match for JSON Pointer "/disk_usage/dev"'
#   at t/web-admin.t line 28.
#                   'rpool/local/root'
#     doesn't match '(?^:/dev/)'
Use of uninitialized value in pattern match (m//) at /build/source/blib/lib/Convos/Controller/Admin.pm line 50.
# Looks like you failed 1 test of 63.
t/web-admin.t .................... Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/63 subtests
t/web-base-url.t ................. 1/? [2020-07-18 17:19:56.43523] [802] [error] [OJICQax7] X-Request-Base header was seen, but CONVOS_REVERSE_PROXY is not set

nix-review build fails with:

@danieldk Thanks for reviewing. I've updated the commit to include a patch for the failed test on zfs as well.

Still fails with the same error, but you probably already saw that in AArch64 ofborg.

Third time's a charm :four_leaf_clover: . Works now!


Failed to use tf.profiler.experimental.Profile API to profiler model

System information

OS Platform: Ubuntu 18.04
TensorFlow installed from source
TensorFlow version: tf==2.1.0, merge-200413-0-g129dd9a34e 2.1.0
Rocm version: rocm==3.3.0
Python version: python==3.6.9
Bazel version (if compiling from source):
GCC/Compiler version: 7.5.0
GPU model and memory: Vega 20, 16GB

Describe the current behavior
I want to profile a CNN model on AMD GPU, my model is implement by tf.keras API,  but get error profiler output:
Here is my profiler test code:  （This works ok and profile correct result using NVIDIA GPU）
import tensorflow as tf
from tensorflow.keras.layers import Dense, Flatten, Conv2D
from tensorflow.keras import Model
import os

# os.environ['CUDA_VISIBLE_DEVICES'] = '0'

class MyModel(Model):
    def __init__(self):
        super(MyModel, self).__init__()
        self.conv1 = Conv2D(filters=512, kernel_size=3, activation='relu')
        self.conv2 = Conv2D(filters=256, kernel_size=3, activation='relu')
        self.conv3 = Conv2D(filters=256, kernel_size=7, activation='relu')
        self.flatten = Flatten()
        self.d1 = Dense(units=128, activation='relu')
        self.d2 = Dense(units=10, activation='softmax')

    @tf.function
    def call(self, x):
        x = self.conv1(x)
        x = self.conv2(x)
        x = self.conv3(x)
        x = self.flatten(x)
        x = self.d1(x)
        return self.d2(x)

model = MyModel()
input_shape = [1, 64, 64, 3]
# model = MyModel()
model(tf.ones(input_shape))

with tf.device('/GPU:0'):
       with tf.profiler.experimental.Profile(logdir='temp'):
           outs = model(tf.ones(input_shape))

print('Profile v2 done!')

After execute above code, Tensorflow print many errors: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.,  It seems that many Op failed to trace. So I want to know how to profile model on AMD GPU with tensorflow>=2.1.0 ?  many thank.
tf outputs:
python3.6 test_profile.py
2020-07-06 13:19:13.492291: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library libhip_hcc.so
2020-07-06 13:19:13.580602: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1561] Found device 0 with properties:
pciBusID: 0000:1c:00.0 name: Vega 20     ROCm AMD GPU ISA: gfx906
coreClock: 1.801GHz coreCount: 60 deviceMemorySize: 15.98GiB deviceMemoryBandwidth: 953.67GiB/s
2020-07-06 13:19:13.631531: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library librocblas.so
2020-07-06 13:19:13.632684: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library libMIOpen.so
2020-07-06 13:19:13.635016: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library librocfft.so
2020-07-06 13:19:13.635192: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library librocrand.so
2020-07-06 13:19:13.635262: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1685] Adding visible gpu devices: 0
2020-07-06 13:19:13.635525: I tensorflow/core/platform/cpu_feature_guard.cc:142] This TensorFlow binary is optimized with Intel(R) MKL-DNN to use the following CPU instructions in performance-critical operations:  AVX512F
To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
2020-07-06 13:19:13.640835: I tensorflow/core/platform/profile_utils/cpu_utils.cc:102] CPU Frequency:<PHONE_NUMBER> Hz
2020-07-06 13:19:13.642456: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x4d73780 initialized for platform Host (this does not guarantee that XLA will be used). Devices:
2020-07-06 13:19:13.642503: I tensorflow/compiler/xla/service/service.cc:176]   StreamExecutor device (0): Host, Default Version
2020-07-06 13:19:13.645587: I tensorflow/compiler/xla/service/service.cc:168] XLA service 0x73311c0 initialized for platform ROCM (this does not guarantee that XLA will be used). Devices:
2020-07-06 13:19:13.645622: I tensorflow/compiler/xla/service/service.cc:176]   StreamExecutor device (0): Vega 20, AMDGPU ISA version: gfx906
2020-07-06 13:19:13.645916: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1561] Found device 0 with properties:
pciBusID: 0000:1c:00.0 name: Vega 20     ROCm AMD GPU ISA: gfx906
coreClock: 1.801GHz coreCount: 60 deviceMemorySize: 15.98GiB deviceMemoryBandwidth: 953.67GiB/s
2020-07-06 13:19:13.645969: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library librocblas.so
2020-07-06 13:19:13.645995: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library libMIOpen.so
2020-07-06 13:19:13.646018: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library librocfft.so
2020-07-06 13:19:13.646040: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library librocrand.so
2020-07-06 13:19:13.646123: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1685] Adding visible gpu devices: 0
2020-07-06 13:19:13.646146: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1084] Device interconnect StreamExecutor with strength 1 edge matrix:
2020-07-06 13:19:13.646160: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1090]      0
2020-07-06 13:19:13.646172: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1103] 0:   N
2020-07-06 13:19:13.646305: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1229] Created TensorFlow device (/job:localhost/replica:0/task:0/device:GPU:0 with 15145 MB memory) -> physical GPU (device: 0, name: Vega 20, pci bus id: 0000:1c:00.0)
2020-07-06 13:19:19.304584: I tensorflow/core/graph/gpu_fusion_pass.cc:505] ROCm Fusion is enabled.
2020-07-06 13:19:19.306426: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library librocblas.so
2020-07-06 13:19:19.307372: I tensorflow/stream_executor/platform/default/dso_loader.cc:44] Successfully opened dynamic library libMIOpen.so
MIOpen(HIP): Warning [SQLiteBase] Unable to read system database file:/opt/rocm-3.3.0/miopen/share/miopen/db/miopen.db Performance may degrade
MIOpen(HIP): Warning [FindDataDirectSolutions] /root/driver/MLOpen/src/include/miopen/sqlite_db.hpp:209: Internal error while accessing SQLite database: unable to open database file
MIOpen(HIP): Warning [FindDataDirectSolutions] /root/driver/MLOpen/src/include/miopen/sqlite_db.hpp:209: Internal error while accessing SQLite database: unable to open database file
MIOpen(HIP): Warning [FindDataDirectSolutions] /root/driver/MLOpen/src/include/miopen/sqlite_db.hpp:209: Internal error while accessing SQLite database: unable to open database file
2020-07-06 13:19:27.832672: I tensorflow/core/profiler/lib/profiler_session.cc:154] Profiler session started.
2020-07-06 13:19:27.832742: I tensorflow/core/profiler/internal/gpu/rocm_tracer.cc:743] Profiler found 1 GPUs
2020-07-06 13:19:27.832763: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:583] GpuTracer created.
2020-07-06 13:19:27.836269: I tensorflow/core/profiler/internal/gpu/rocm_tracer.cc:757] GpuTracer started
2020-07-06 13:19:27.839595: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : Activity event encountered before a corresponding API event.
2020-07-06 13:19:27.840591: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : Activity event encountered before a corresponding API event.
2020-07-06 13:19:27.840633: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840683: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840701: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840716: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840732: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840746: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:199] Mapping physical device id 0 to logical device id 0
2020-07-06 13:19:27.840760: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840775: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840790: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840816: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840840: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840855: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840869: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840883: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840899: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.
2020-07-06 13:19:27.840927: I tensorflow/core/profiler/internal/gpu/rocm_tracer.cc:768] GpuTracer stopped
2020-07-06 13:19:27.842305: I tensorflow/core/profiler/rpc/client/save_profile.cc:168] Creating directory: temp/plugins/profile/2020_07_06_13_19_27
2020-07-06 13:19:27.842913: I tensorflow/core/profiler/rpc/client/save_profile.cc:174] Dumped gzipped tool data for trace.json.gz to temp/plugins/profile/2020_07_06_13_19_27/ubuntu.trace.json.gz
2020-07-06 13:19:27.842992: E tensorflow/core/profiler/utils/hardware_type_utils.cc:60] Invalid GPU compute capability.
2020-07-06 13:19:27.843468: I tensorflow/core/profiler/utils/event_span.cc:288] Generation of step-events took 0 ms

2020-07-06 13:19:27.844651: I tensorflow/python/profiler/internal/profiler_wrapper.cc:91] Creating directory: temp/plugins/profile/2020_07_06_13_19_27Dumped tool data for overview_page.pb to temp/plugins/profile/2020_07_06_13_19_27/ubuntu.overview_page.pb
Dumped tool data for input_pipeline.pb to temp/plugins/profile/2020_07_06_13_19_27/ubuntu.input_pipeline.pb
Dumped tool data for tensorflow_stats.pb to temp/plugins/profile/2020_07_06_13_19_27/ubuntu.tensorflow_stats.pb
Dumped tool data for kernel_stats.pb to temp/plugins/profile/2020_07_06_13_19_27/ubuntu.kernel_stats.pb

Profile v2 done!

Describe the expected behavior
Standalone code to reproduce the issue

I also run this model using tensorflow.python.profiler.model_analyzer.Profiler   with tf.compat.v1.disable_eager_execution,  the error info is same:  I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.,   I am not sure is the gpu profiler of Tensorflow or profiler of ROCm exist bugs ?

@deven-amd Does this sounds familiar to you? I remember you have a recent PR that fixed rocTracer, too. Wants to double check because this seems to be on ROCm3.3 context.

@alphaRGB
Can you try a newer TF version. We have only recently (within the last couple of months) finished implementing support for profiling on TF-ROCm and I am unsure whether the version you are using has everything (needed for profiling)
The following error will still be there and can be ignored for now
2020-07-06 13:19:27.842992: E tensorflow/core/profiler/utils/hardware_type_utils.cc:60] Invalid GPU compute capability.

That is because the TF code expects a CUDA style compute capability number in the profiling data (which obviously won't be present on the ROCm platform)
The other message, i.e.
2020-07-06 13:19:27.840899: I tensorflow/core/profiler/internal/gpu/device_tracer_rocm.cc:177] RocmTracerEvent(s) dropped (1) : invalid stream id.

is somewhat problematic, and ideally you should not see those at all. As the message output indicates, it means that the data for some event had to be dropped because there was inconsistency found within it (invalid stream id in this case).  If you get a few of these when the number of events being collected are in the thousands, it is no big deal (since amount of lost data is insignificant), but you should not be seeing any for a testcase this small

another sugegstion I have is to use the method outlined in the TF tutorial here
https://www.tensorflow.org/tensorboard/tensorboard_profiling_keras
to dump the profiling data. I just tried it on a simple example (using TF build from source on develop-upstream branch) and it works

@deven-amd  thank you, I will test the TF tutorial demo first.   And which ROCm version you tried?

I have test the demo of  "tensorboard_profiling_keras" in the url with TF 2.1 (merge-200413-0-g129dd9a34e 2.1.0) + ROCm3.3.0.
Due to the network reason, sorry I can't provide you detaild pictures of Tensorboard.  In the PROFILER page of tensorboard.
Performance Summary are all zeros on AMD GPU, it is seems error.   while I run same code on NVIDIA, most values are not zeros:
Performance Summary (NVIDIA)

Average Step Time: 7.5 ms
All Others Time: 1.0 ms
Compliation Time: 0.0 ms
Output Time: 0.0 ms
Input Time 0.0 ms
Kernel Launch Time: 0.9 ms
Host Compte Time: 0.1 ms
Decie to Device Time: 0.0 ms
Device Compute Time: 5.4 ms

There seems that the profier of Tensorflow-rocm I used may exists problem, I'll try a new TF with newer ROCm.

@alphaRGB TF2.1 is probably still too old. Could you maybe try the following two docker images? Or if you'd rather build by youself, use the commit id of tensorflow follows rocm version.
For ROCm 3.5:
docker pull rocm/tensorflow-autobuilds:rocm3.5-760bec0
For ROCm 3.3:
docker pull rocm/tensorflow-autobuilds:rocm3.3-9ca344d

@jerryyin  Thank for your advice and  provided TF.  but we can't use docker, so I  tried to build Tensorflow (commit id = 760bec0)  with ROCm==3.5.0, but complied failed.  Could you help me check  the TF compile errors?  Can you share a  prebuild  TF(760bec0) whl package if you have build it with success.
ROCm
I installed ROCm using these cmds, then set LD_LIBRARY_PATH=/opt/rocm-3.5.0/libs PATH=/opt/rocm-3.5.0/bin,   the rocm-smi , rocminfo and clinfo works ok.
sudo apt-get install rocm-dkms3.5.0
sudo apt install rocm-libs3.5.0 miopen-hip3.5.0 rccl3.5.0
sudo apt-get install miopengemm3.5.0

Build Tensorflow

bazel==3.1.0
python==3.6.9
ROCm==3.5.0

TF build cmd
I have download third-parts before, then set distdir while compile
ROCM_PATH=/opt/rocm-3.5.0 TF_NEED_ROCM=1 PYTHON_BIN_PATH=/usr/bin/python3 ./configure
bazel build --distdir /data/tf_thirdpart_downloads/downloads/ --config=opt --config=rocm //tensorflow/tools/pip_package:build_pip_package --verbose_failures

Errors

ERROR: /home/fimhbm/penghui_wei/Tensorflow/tf-amd/tensorflow-upstream-760bec08ba01c374b44015493b975c6d52beb324/tensorflow/core/kernels/rnn/BUILD:54:1: C++ compilation of rule '//tensorflow/core/kernels/rnn:gru_ops_gpu' failed (Exit 1): crosstool_wrapper_driver_is_not_gcc failed: error executing command
(cd /home/fimhbm/.cache/bazel/_bazel_fimhbm/aff401f30ba583f7f12006ac9f35b87c/execroot/org_tensorflow &&
exec env -
LD_LIBRARY_PATH=/opt/rocm/lib:
external/local_config_rocm/crosstool/clang/bin/crosstool_wrapper_driver_is_not_gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections '-std=c++11' -MD -MF bazel

clang-11: warning: argument unused during compilation: '--hip-device-lib-path=/opt/rocm-3.5.0/lib' [-Wunused-command-line-argument]
lld: error: undefined symbol: ldexp(float, int)

The error "'//tensorflow/core/kernels/rnn:gru_ops_gpu' failed (Exit 1): crosstool_wrapper_driver_is_not_gcc failed: error executing command" seem samilar to [#1036 ].
The error "lld: error: undefined symbol: ldexp(float, int) " and "clang-11: warning: argument unused during compilation”  seems casused by clang,  I think the "clang-11" complier may not find .so or .a files, so I set LD_LIBRARY_PATH=/opt/rocm-3.5.0/llvm, it not works, same error.
Also,  I think the error may be casused by compliler with FLASG=std=c++11, so I have tried: --cxxopt="-D_GLIBCXX_USE_CXX11_ABI=0"  with bazel build, but the error is same.

error log
INFO: From Compiling tensorflow/core/kernels/data/experimental/dense_to_sparse_batch_dataset_op.cc [for host]:
In file included from ./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX512.h:4:0,
                 from ./third_party/eigen3/unsupported/Eigen/CXX11/FixedPoint:35,
                 from ./tensorflow/core/framework/numeric_types.h:24,
                 from ./tensorflow/core/framework/allocator.h:26,
                 from ./tensorflow/core/framework/tensor.h:23,
                 from ./tensorflow/core/framework/attr_value_util.h:24,
                 from ./tensorflow/core/framework/dataset.h:24,
                 from tensorflow/core/kernels/data/experimental/dense_to_sparse_batch_dataset_op.cc:15:
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX2.h:30:41: warning: ignoring attributes on template argument '__m256i {aka __vector(4) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m256i, 20> Packet32q8i;
                                         ^
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX2.h:31:41: warning: ignoring attributes on template argument '__m256i {aka __vector(4) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m256i, 21> Packet16q16i;
                                         ^
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX2.h:32:41: warning: ignoring attributes on template argument '__m256i {aka __vector(4) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m256i, 22> Packet32q8u;
                                         ^
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX2.h:33:41: warning: ignoring attributes on template argument '__m128i {aka __vector(2) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m128i, 23> Packet16q8i;
                                         ^
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX2.h:34:41: warning: ignoring attributes on template argument '__m128i {aka __vector(2) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m128i, 25> Packet16q8u;
                                         ^
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX2.h:35:41: warning: ignoring attributes on template argument '__m128i {aka __vector(2) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m128i, 26> Packet8q16i;
                                         ^
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX2.h:36:41: warning: ignoring attributes on template argument '__m256i {aka __vector(4) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m256i, 27> Packet8q32i;
                                         ^
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX2.h:37:41: warning: ignoring attributes on template argument '__m128i {aka __vector(2) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m128i, 28> Packet4q32i;
                                         ^
In file included from ./third_party/eigen3/unsupported/Eigen/CXX11/FixedPoint:35:0,
                 from ./tensorflow/core/framework/numeric_types.h:24,
                 from ./tensorflow/core/framework/allocator.h:26,
                 from ./tensorflow/core/framework/tensor.h:23,
                 from ./tensorflow/core/framework/attr_value_util.h:24,
                 from ./tensorflow/core/framework/dataset.h:24,
                 from tensorflow/core/kernels/data/experimental/dense_to_sparse_batch_dataset_op.cc:15:
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX512.h:9:41: warning: ignoring attributes on template argument '__m512i {aka __vector(8) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m512i, 30> Packet64q8i;
                                         ^
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX512.h:10:41: warning: ignoring attributes on template argument '__m512i {aka __vector(8) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m512i, 31> Packet32q16i;
                                         ^
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX512.h:11:41: warning: ignoring attributes on template argument '__m512i {aka __vector(8) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m512i, 32> Packet64q8u;
                                         ^
./third_party/eigen3/unsupported/Eigen/CXX11/src/FixedPoint/PacketMathAVX512.h:12:41: warning: ignoring attributes on template argument '__m512i {aka __vector(8) long long int}' [-Wignored-attributes]
 typedef eigen_packet_wrapper<__m512i, 33> Packet16q32i;
                                         ^
ERROR: /home/fimhbm/penghui_wei/Tensorflow/tf-amd/tensorflow-upstream-760bec08ba01c374b44015493b975c6d52beb324/tensorflow/core/kernels/rnn/BUILD:54:1: C++ compilation of rule '//tensorflow/core/kernels/rnn:gru_ops_gpu' failed (Exit 1): crosstool_wrapper_driver_is_not_gcc failed: error executing command
  (cd /home/fimhbm/.cache/bazel/_bazel_fimhbm/aff401f30ba583f7f12006ac9f35b87c/execroot/org_tensorflow && \
  exec env - \
    LD_LIBRARY_PATH=/opt/rocm/lib: \
    PATH=/usr/local/bin:/home/fimhbm/.vscode-server/bin/cd9ea6488829f560dc949a8b2fb789f3cdc05f5d/bin:/home/fimhbm/.local/bin:/home/fimhbm/bin:/usr/local/bin:/home/WPH/Softwares/anaconda3/condabin:/home/fimhbm/.vscode-server/bin/cd9ea6488829f560dc949a8b2fb789f3cdc05f5d/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/opt/rocm/bin:/opt/rocm/opencl/bin \
    PWD=/proc/self/cwd \
  external/local_config_rocm/crosstool/clang/bin/crosstool_wrapper_driver_is_not_gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections '-std=c++11' -MD -MF bazel-out/host/bin/tensorflow/core/kernels/rnn/_objs/gru_ops_gpu/gru_ops_gpu.cu.pic.d '-frandom-seed=bazel-out/host/bin/tensorflow/core/kernels/rnn/_objs/gru_ops_gpu/gru_ops_gpu.cu.pic.o' -fPIC -DTENSORFLOW_USE_CUSTOM_CONTRACTION_KERNEL -DTENSORFLOW_USE_MKLDNN_CONTRACTION_KERNEL -DEIGEN_MPL2_ONLY '-DEIGEN_MAX_ALIGN_BYTES=64' '-DEIGEN_HAS_TYPE_TRAITS=0' -D__CLANG_SUPPORT_DYN_ANNOTATION__ -iquote . -iquote bazel-out/host/bin -iquote external/com_google_absl -iquote bazel-out/host/bin/external/com_google_absl -iquote external/eigen_archive -iquote bazel-out/host/bin/external/eigen_archive -iquote external/local_config_sycl -iquote bazel-out/host/bin/external/local_config_sycl -iquote external/nsync -iquote bazel-out/host/bin/external/nsync -iquote external/gif -iquote bazel-out/host/bin/external/gif -iquote external/libjpeg_turbo -iquote bazel-out/host/bin/external/libjpeg_turbo -iquote external/com_google_protobuf -iquote bazel-out/host/bin/external/com_google_protobuf -iquote external/com_googlesource_code_re2 -iquote bazel-out/host/bin/external/com_googlesource_code_re2 -iquote external/farmhash_archive -iquote bazel-out/host/bin/external/farmhash_archive -iquote external/fft2d -iquote bazel-out/host/bin/external/fft2d -iquote external/highwayhash -iquote bazel-out/host/bin/external/highwayhash -iquote external/zlib -iquote bazel-out/host/bin/external/zlib -iquote external/local_config_rocm -iquote bazel-out/host/bin/external/local_config_rocm -iquote external/local_config_cuda -iquote bazel-out/host/bin/external/local_config_cuda -iquote external/local_config_tensorrt -iquote bazel-out/host/bin/external/local_config_tensorrt -iquote external/mkl_dnn -iquote bazel-out/host/bin/external/mkl_dnn -Ibazel-out/host/bin/external/local_config_cuda/cuda/_virtual_includes/cuda_headers_virtual -Ibazel-out/host/bin/external/local_config_tensorrt/_virtual_includes/tensorrt_headers -isystem external/eigen_archive -isystem bazel-out/host/bin/external/eigen_archive -isystem external/nsync/public -isystem bazel-out/host/bin/external/nsync/public -isystem external/gif -isystem bazel-out/host/bin/external/gif -isystem external/com_google_protobuf/src -isystem bazel-out/host/bin/external/com_google_protobuf/src -isystem external/farmhash_archive/src -isystem bazel-out/host/bin/external/farmhash_archive/src -isystem external/zlib -isystem bazel-out/host/bin/external/zlib -isystem external/local_config_rocm/rocm -isystem bazel-out/host/bin/external/local_config_rocm/rocm -isystem external/local_config_rocm/rocm/rocm/include -isystem bazel-out/host/bin/external/local_config_rocm/rocm/rocm/include -isystem external/local_config_rocm/rocm/rocm/include/rocrand -isystem bazel-out/host/bin/external/local_config_rocm/rocm/rocm/include/rocrand -isystem external/local_config_rocm/rocm/rocm/include/roctracer -isystem bazel-out/host/bin/external/local_config_rocm/rocm/rocm/include/roctracer -isystem external/local_config_cuda/cuda -isystem bazel-out/host/bin/external/local_config_cuda/cuda -isystem external/local_config_cuda/cuda/cuda/include -isystem bazel-out/host/bin/external/local_config_cuda/cuda/cuda/include -isystem external/mkl_dnn/include -isystem bazel-out/host/bin/external/mkl_dnn/include -isystem external/mkl_dnn/src -isystem bazel-out/host/bin/external/mkl_dnn/src -isystem external/mkl_dnn/src/common -isystem bazel-out/host/bin/external/mkl_dnn/src/common -isystem external/mkl_dnn/src/cpu -isystem bazel-out/host/bin/external/mkl_dnn/src/cpu -isystem external/mkl_dnn/src/cpu/gemm -isystem bazel-out/host/bin/external/mkl_dnn/src/cpu/gemm -isystem external/mkl_dnn/src/cpu/xbyak -isystem bazel-out/host/bin/external/mkl_dnn/src/cpu/xbyak -g0 '-march=native' -g0 '-std=c++14' -DEIGEN_AVOID_STL_ARRAY -Iexternal/gemmlowp -Wno-sign-compare '-ftemplate-depth=900' -fno-exceptions '-DTENSORFLOW_USE_XLA=1' '-DTENSORFLOW_USE_ROCM=1' -msse3 -pthread -x rocm -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' '-DTENSORFLOW_USE_ROCM=1' -D__HIP_PLATFORM_HCC__ -DEIGEN_USE_HIP '-DTENSORFLOW_COMPILER_IS_HIP_CLANG=1' -no-canonical-prefixes -fno-canonical-system-headers -c tensorflow/core/kernels/rnn/gru_ops_gpu.cu.cc -o bazel-out/host/bin/tensorflow/core/kernels/rnn/_objs/gru_ops_gpu/gru_ops_gpu.cu.pic.o)
Execution platform: @local_execution_config_platform//:platform
clang-11: warning: argument unused during compilation: '--hip-device-lib-path=/opt/rocm-3.5.0/lib' [-Wunused-command-line-argument]
lld: error: undefined symbol: ldexp(float, int)
>>> referenced by /tmp/gru_ops_gpu-919f0d-gfx906-9f8e5c.o:(void Eigen::internal::EigenMetaKernel<Eigen::TensorEvaluator<Eigen::TensorAssignOp<Eigen::TensorMap<Eigen::Tensor<float, 2, 1, long>, 16, Eigen::MakePointer>, Eigen::TensorCwiseUnaryOp<Eigen::internal::scalar_logistic_op<float>, Eigen::TensorSlicingOp<Eigen::array<long, 2ul> const, Eigen::array<long, 2ul> const, Eigen::TensorMap<Eigen::Tensor<float, 2, 1, long>, 16, Eigen::MakePointer> > const> const> const, Eigen::GpuDevice>, long>(Eigen::TensorEvaluator<Eigen::TensorAssignOp<Eigen::TensorMap<Eigen::Tensor<float, 2, 1, long>, 16, Eigen::MakePointer>, Eigen::TensorCwiseUnaryOp<Eigen::internal::scalar_logistic_op<float>, Eigen::TensorSlicingOp<Eigen::array<long, 2ul> const, Eigen::array<long, 2ul> const, Eigen::TensorMap<Eigen::Tensor<float, 2, 1, long>, 16, Eigen::MakePointer> > const> const> const, Eigen::GpuDevice>, long))
>>> referenced by /tmp/gru_ops_gpu-919f0d-gfx906-9f8e5c.o:(void Eigen::internal::EigenMetaKernel<Eigen::TensorEvaluator<Eigen::TensorAssignOp<Eigen::TensorMap<Eigen::Tensor<float, 2, 1, long>, 16, Eigen::MakePointer>, Eigen::TensorCwiseUnaryOp<Eigen::internal::scalar_logistic_op<float>, Eigen::TensorSlicingOp<Eigen::array<long, 2ul> const, Eigen::array<long, 2ul> const, Eigen::TensorMap<Eigen::Tensor<float, 2, 1, long>, 16, Eigen::MakePointer> > const> const> const, Eigen::GpuDevice>, long>(Eigen::TensorEvaluator<Eigen::TensorAssignOp<Eigen::TensorMap<Eigen::Tensor<float, 2, 1, long>, 16, Eigen::MakePointer>, Eigen::TensorCwiseUnaryOp<Eigen::internal::scalar_logistic_op<float>, Eigen::TensorSlicingOp<Eigen::array<long, 2ul> const, Eigen::array<long, 2ul> const, Eigen::TensorMap<Eigen::Tensor<float, 2, 1, long>, 16, Eigen::MakePointer> > const> const> const, Eigen::GpuDevice>, long))
clang-11: error: amdgcn-link command failed with exit code 1 (use -v to see invocation)
Target //tensorflow/tools/pip_package:build_pip_package failed to build
ERROR: /home/fimhbm/penghui_wei/Tensorflow/tf-amd/tensorflow-upstream-760bec08ba01c374b44015493b975c6d52beb324/tensorflow/tools/pip_package/BUILD:66:1 C++ compilation of rule '//tensorflow/core/kernels/rnn:gru_ops_gpu' failed (Exit 1): crosstool_wrapper_driver_is_not_gcc failed: error executing command
  (cd /home/fimhbm/.cache/bazel/_bazel_fimhbm/aff401f30ba583f7f12006ac9f35b87c/execroot/org_tensorflow && \
  exec env - \
    LD_LIBRARY_PATH=/opt/rocm/lib: \
    PATH=/usr/local/bin:/home/fimhbm/.vscode-server/bin/cd9ea6488829f560dc949a8b2fb789f3cdc05f5d/bin:/home/fimhbm/.local/bin:/home/fimhbm/bin:/usr/local/bin:/home/WPH/Softwares/anaconda3/condabin:/home/fimhbm/.vscode-server/bin/cd9ea6488829f560dc949a8b2fb789f3cdc05f5d/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/opt/rocm/bin:/opt/rocm/opencl/bin \
    PWD=/proc/self/cwd \
  external/local_config_rocm/crosstool/clang/bin/crosstool_wrapper_driver_is_not_gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections -fdata-sections '-std=c++11' -MD -MF bazel-out/host/bin/tensorflow/core/kernels/rnn/_objs/gru_ops_gpu/gru_ops_gpu.cu.pic.d '-frandom-seed=bazel-out/host/bin/tensorflow/core/kernels/rnn/_objs/gru_ops_gpu/gru_ops_gpu.cu.pic.o' -fPIC -DTENSORFLOW_USE_CUSTOM_CONTRACTION_KERNEL -DTENSORFLOW_USE_MKLDNN_CONTRACTION_KERNEL -DEIGEN_MPL2_ONLY '-DEIGEN_MAX_ALIGN_BYTES=64' '-DEIGEN_HAS_TYPE_TRAITS=0' -D__CLANG_SUPPORT_DYN_ANNOTATION__ -iquote . -iquote bazel-out/host/bin -iquote external/com_google_absl -iquote bazel-out/host/bin/external/com_google_absl -iquote external/eigen_archive -iquote bazel-out/host/bin/external/eigen_archive -iquote external/local_config_sycl -iquote bazel-out/host/bin/external/local_config_sycl -iquote external/nsync -iquote bazel-out/host/bin/external/nsync -iquote external/gif -iquote bazel-out/host/bin/external/gif -iquote external/libjpeg_turbo -iquote bazel-out/host/bin/external/libjpeg_turbo -iquote external/com_google_protobuf -iquote bazel-out/host/bin/external/com_google_protobuf -iquote external/com_googlesource_code_re2 -iquote bazel-out/host/bin/external/com_googlesource_code_re2 -iquote external/farmhash_archive -iquote bazel-out/host/bin/external/farmhash_archive -iquote external/fft2d -iquote bazel-out/host/bin/external/fft2d -iquote external/highwayhash -iquote bazel-out/host/bin/external/highwayhash -iquote external/zlib -iquote bazel-out/host/bin/external/zlib -iquote external/local_config_rocm -iquote bazel-out/host/bin/external/local_config_rocm -iquote external/local_config_cuda -iquote bazel-out/host/bin/external/local_config_cuda -iquote external/local_config_tensorrt -iquote bazel-out/host/bin/external/local_config_tensorrt -iquote external/mkl_dnn -iquote bazel-out/host/bin/external/mkl_dnn -Ibazel-out/host/bin/external/local_config_cuda/cuda/_virtual_includes/cuda_headers_virtual -Ibazel-out/host/bin/external/local_config_tensorrt/_virtual_includes/tensorrt_headers -isystem external/eigen_archive -isystem bazel-out/host/bin/external/eigen_archive -isystem external/nsync/public -isystem bazel-out/host/bin/external/nsync/public -isystem external/gif -isystem bazel-out/host/bin/external/gif -isystem external/com_google_protobuf/src -isystem bazel-out/host/bin/external/com_google_protobuf/src -isystem external/farmhash_archive/src -isystem bazel-out/host/bin/external/farmhash_archive/src -isystem external/zlib -isystem bazel-out/host/bin/external/zlib -isystem external/local_config_rocm/rocm -isystem bazel-out/host/bin/external/local_config_rocm/rocm -isystem external/local_config_rocm/rocm/rocm/include -isystem bazel-out/host/bin/external/local_config_rocm/rocm/rocm/include -isystem external/local_config_rocm/rocm/rocm/include/rocrand -isystem bazel-out/host/bin/external/local_config_rocm/rocm/rocm/include/rocrand -isystem external/local_config_rocm/rocm/rocm/include/roctracer -isystem bazel-out/host/bin/external/local_config_rocm/rocm/rocm/include/roctracer -isystem external/local_config_cuda/cuda -isystem bazel-out/host/bin/external/local_config_cuda/cuda -isystem external/local_config_cuda/cuda/cuda/include -isystem bazel-out/host/bin/external/local_config_cuda/cuda/cuda/include -isystem external/mkl_dnn/include -isystem bazel-out/host/bin/external/mkl_dnn/include -isystem external/mkl_dnn/src -isystem bazel-out/host/bin/external/mkl_dnn/src -isystem external/mkl_dnn/src/common -isystem bazel-out/host/bin/external/mkl_dnn/src/common -isystem external/mkl_dnn/src/cpu -isystem bazel-out/host/bin/external/mkl_dnn/src/cpu -isystem external/mkl_dnn/src/cpu/gemm -isystem bazel-out/host/bin/external/mkl_dnn/src/cpu/gemm -isystem external/mkl_dnn/src/cpu/xbyak -isystem bazel-out/host/bin/external/mkl_dnn/src/cpu/xbyak -g0 '-march=native' -g0 '-std=c++14' -DEIGEN_AVOID_STL_ARRAY -Iexternal/gemmlowp -Wno-sign-compare '-ftemplate-depth=900' -fno-exceptions '-DTENSORFLOW_USE_XLA=1' '-DTENSORFLOW_USE_ROCM=1' -msse3 -pthread -x rocm -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE__="redacted"' '-D__TIMESTAMP__="redacted"' '-D__TIME__="redacted"' '-DTENSORFLOW_USE_ROCM=1' -D__HIP_PLATFORM_HCC__ -DEIGEN_USE_HIP '-DTENSORFLOW_COMPILER_IS_HIP_CLANG=1' -no-canonical-prefixes -fno-canonical-system-headers -c tensorflow/core/kernels/rnn/gru_ops_gpu.cu.cc -o bazel-out/host/bin/tensorflow/core/kernels/rnn/_objs/gru_ops_gpu/gru_ops_gpu.cu.pic.o)
Execution platform: @local_execution_config_platform//:platform
INFO: Elapsed time: 1188.356s, Critical Path: 132.95s
INFO: 11806 processes: 11806 local.
FAILED: Build did NOT complete successfully

you have run into the first of two known build errors with ROCm 3.5
both can be workedaround as shown here
https://github.com/ROCmSoftwarePlatform/tensorflow-upstream/blob/develop-upstream/tensorflow/tools/ci_build/Dockerfile.rocm#L121-L126


[Request] Changelog

Having a changelog would be much appreciated in case we want to upgrade our current version of Waterline. There could new features or something that behaves differently to previous version. Looking at commits It's pretty much impossible between releases tell what belongs where.

Done! Changelog

@particlebanana much appreciated


With the animations the feet are not on the ground

Without animation, the feet are on the ground.
In the animations the feet are not on the ground, you can see it with the shadow.

I reopen. I actually fixed the issue for the women with positionOffset: -0.168, but for men it should be a different offset.


[API-78] Implement the Hazelcast Cloud Discovery

Implemented the Hazelcast cloud discovery.

Windows test FAILed.

Windows test FAILed.

Linux test FAILed.

Linux test FAILed.

Windows test FAILed.

Linux test PASSed.

Windows test PASSed.

Linux test PASSed.

Windows test PASSed.

verify-linux

Windows test PASSed.

Linux test PASSed.

Linux test PASSed.

Windows test PASSed.

Linux test PASSed.

Windows test PASSed.

Linux test PASSed.

Windows test PASSed.

Linux test PASSed.

Linux test PASSed.

Windows test PASSed.


minify svg with squoosh?

Hi is it possible to minify (clean, remove comments etc) SVGs with squoosh or will I have to switch to the imagemin version?
alternatively do you have a suggestion for working with svg's separately to squoosh?
thanks
update..
I was hoping to do something like this but it doesn't work... the svg's don't get minified
 .images({
     // jpg, png etc
     implementation: 'squoosh',
     webp: true,
 },
 {
     // svg
     implementation: 'imagemin',
     options: {
         plugins: [
             [
                 "imagemin-svgo",
                 {
                     plugins: ['preset-default']
                 }
             ]
         ]
     }
 })

For squoosh apparently there is no support yet. In your example you used an invalid configuration syntax combining squoosh and imagemin.
Have you tried just using imagemin instead of squoosh entirely?
mix.images({
  implementation: 'imagemin',
  webp: true,
});

Hi, yes I ended up sticking with imagemin implementation as I couldn't get the normal laravel-mix-imagemin to work (some issue with require & copy options)
This will do fine for now thanks


Caching not working

Hi,
I'm using the flagsmith-java-client version 2.8, and I'm initializing the client as it's shown in the tutorial.
Overriding the defaults:
.withCache(FlagsmithCacheConfig                         .newBuilder()                         .maxSize(100)                         .expireAfterWrite(10, TimeUnit.MINUTES)                         .recordStats()                         .build())                 .build();
and using the defaults:
.withCache(FlagsmithCacheConfig                         .newBuilder()                         .build())                 .build()
None of them works. I use the method "getFeatureFlagValue(featureKey)" to retrieve the flag value, but none of the responses is cached.
Also, when checking the cache stats, everything appears setted to zero.
Can you help?
Thanks in advance.

Just doing something like this in Spring boot returns a hitrate of 1:
@RestController
public class HelloController {
	private static FlagsmithClient flagsmith = FlagsmithClient.newBuilder()
		.setApiKey("NowEDzKzNJXZVTVanLVdMQ")
		.withCache(FlagsmithCacheConfig.newBuilder().maxSize(100).expireAfterWrite(10, TimeUnit.MINUTES).recordStats().build())
		.build();

	@RequestMapping("/")
	public String index() {
		String fontSize = flagsmith.getFeatureFlagValue("font_size");
		fontSize = flagsmith.getFeatureFlagValue("font_size");
		fontSize = flagsmith.getFeatureFlagValue("font_size");
		fontSize = flagsmith.getFeatureFlagValue("font_size");
		final FlagsmithCache cache = flagsmith.getCache();
		final CacheStats stats = cache.stats();

		return "cache hitRate: " + stats.hitRate();
	}
}

We would need to see more of your code to be able to diagnose this

My 2 cents worth: the Java SDK currently only supports caching for the following methods:

getFeatureFlags* cache is supported if the user is provided. Project level flags are not currently cached. I haven't implemented this yet because I didn't need it at the time (but it looks like we will start using project level flags soon, so I will be adding support for this in the coming weeks).
getUserFlagsAndTraits
postUserTraits
identifyUserWithTraits: calling this method always invalidates the cache for the specific user. The reason being that adding caching support for this method requires extra logic (comparing all traits in the cache vs the traits provided as a parameter). I may add support for this method in the upcoming weeks.

Disclaimer: I am not part of the Flagsmith team, I am just contributing because I also use this SDK in my projects and I enjoy contributing.

Hi all,
Thanks for your responses, and sorry for my late feedback. @sw-tracker it's exactly what you said, thank you!
I've checked the code and noticed that it would only work if I passed the FeatureUser. so I've made it work that way.
@dabeeeenster, an update to the documentation would be nice :)
Thank you all.

@Nunovsky Flagsmith just merged my PR to support caching on all endpoints. It should be available in version 3.1 once it is published in maven.

@nagomirachel are you able to provide a little more information about your issue please?
When you say 'I'm not able to get the value' - what exactly do you mean?
Can you share your code and any exceptions that you're seeing?

@Nunovsky would you mind sharing your flagsmith client configuration code?
To be able to enable caching at a project level, you need to provide a key (to ensure that there are no clashes with user identifiers). For example:
private static FlagsmithClient flagsmith = FlagsmithClient.newBuilder()
		.setApiKey("NowEDzKzNJXZVTVanLVdMQ")
		.withCache(FlagsmithCacheConfig.newBuilder().enableEnvLevelCaching("some-key-that-wont-clash-with-user-IDs").build())
		.build();

The important part is:
.enableEnvLevelCaching("some-key-that-wont-clash-with-user-IDs")

This is documented in the code but not on the SDK website, I will add it.

@nagomirachel are you able to provide a little more information about your issue please?
When you say 'I'm not able to get the value' - what exactly do you mean?
Can you share your code and any exceptions that you're seeing?

private static FlagsmithClient flagsmith = FlagsmithClient.newBuilder()
//.setApiKey("")
.setApiKey("")
.withApiUrl("http://localhost:8000/")
.build();
/**

A default configuration for the Flagsmith client SDK.

**/
@RequestMapping("/")
public String index() {
String fontSize = flagsmith.getFeatureFlagValue("font_size");
FeatureUser user = new FeatureUser();
user.setIdentifier("*myuser");
boolean featureEnabled = flagsmith.hasFeatureFlag("font_size", user);
if (featureEnabled) {
// run the code that executes the enabled feature for a given user
return "Greetings from Spring Boot inside if ! Font size is " + fontSize;
} else {
// run the code that doesn't include the feature
System.out.println("font size" + fontSize);
}
return "Greetings from Spring Boot! Font size is " + fontSize;

}
I have a flagsmith setup in local, have created a feature font size and enabled it.
From github https://github.com/flagsmith/flagsmith/ , imported code to my visual studio.
Copied hellocontroller&application from example and pasted inside root src/main/java.
Above code is in controller.
AS per the suggestions, edited the feature user java code and provided pojos to set the value of user.
I have set the value of user as above and  built my maven code ,
Output is :2022-02-16 18:22:33.422  INFO 22999 --- [nio-8080-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
font sizenull

@nagomirachel is this your entire configuration?
private static FlagsmithClient flagsmith = FlagsmithClient.newBuilder()
//.setApiKey("")
.setApiKey("")
.withApiUrl("http://localhost:8000/")
.build();

You are not enabling caching. Caching is disabled by default, please add this to your configuration:
private static FlagsmithClient flagsmith = FlagsmithClient.newBuilder()
//.setApiKey("")
.setApiKey("")
.withApiUrl("http://localhost:8000/")
.withCache(FlagsmithCacheConfig.newBuilder().enableEnvLevelCaching("some-key-that-wont-clash-with-user-IDs").build())
.build();

And set "some-key-that-wont-clash-with-user-IDs" to a value that can never be a user identifier in flagsmith. The documentation tells you what are the default cache settings: https://docs.flagsmith.com/clients/java#in-memory-caching.
I am working on enhancing the docs right now.
Disclaimer: I am not a member of the Flagsmith team.

@sw-tracker Thanks for the help. But still im not able to retrieve the flag detail. Im not sure if I am missing any details .
Output of the application after adding caching values
2022-02-17 10:48:31.405  INFO 26383 --- [nio-8080-exec-1] o.s.web.servlet.DispatcherServlet        : Completed initialization in 1 ms
Check Feature enabled or notfalse
font size in else statement: null
Check Feature enabled or notfalse - This I tried to print the output of line:
boolean featureEnabled = flagsmith.hasFeatureFlag("font_size", user);
Attaching pojo class for ref. Let me know if I have to check anything else
@Data
public class FeatureUser {
private String identifier;
public FeatureUser(){
this.identifier = identifier;
}
public String getIdentifier() {
return identifier;
}
public void setIdentifier(String identifier) {
this.identifier = identifier;
}
}

hi @anyone , can anyone help me sort out the issues. I am not sure if my java code hits the flagsmith and gets the data . how do i check

@nagomirachel it seems like your issue has nothing to do with caching (given that you haven't activated it in your config). You are writing on a closed issue by the way.
At first glance, I would say your URL is incorrect. Have you tried with postman first? You might have to add /api/v1 to your URL (at least that's how I have it configured on mine).


feat: expose the WithQuotaProject dialer option

This option is available as google.golang.org/api/option to the
gcloud go api. It needs to be exposed in the cloud sql connector
also.

FYI: Go likes to capitalize all its acronyms, so get used to writing API, HTTP, IP, etc. ;-)


Add some words to glossary

Starting point, to see how it behaves.
I didn't update the stump that was already there (dan/kyus/...)
note @kazk : what do you expect to write about TDD considering the TODO note that is there?

#23

...okay... I totally failed the formatting... x)
Surely the multiline description that are wrong. I'll see about that tomorrow (if anyone has the answer on hand, do not hesitate to tell me... x) )

note @kazk : what do you expect to write about TDD considering the TODO note that is there?

Nothing. That was just an example to show you guys that Markdown can be used :)

It was failing because you had : in unquoted string which is a reserved character.
Quoting a string is optional in YAML, but you can run into issues like this.

x/
Damn it... The linter swallows it, but the other verifications are failing and I don't get why...

no colons
I tried removing the / in the term section of Approve (kata/translation)
I just corrected a typo and exchanged 2 terms that weren't in alphabetic order

... => ?? :(

Other checks failed because of some cache issues on Netlify Build. Probably related packages on this branch not matching the one on master because I updated some few days ago.
I rebuilt after clearing the cache and it’s fine now.
Don’t merge this yet. I’ll squash merge later because commits are messy.


Use local dependency for kube-prometheus jsonnet

Once we merge https://github.com/jsonnet-bundler/jsonnet-bundler/pull/36 we can make use of local dependencies with jsonnet-bundler.
Before the build for this PR in the CI succeeds, we need to update jb in the CI image (/cc @paulfantom).
/cc @brancz @LiliC @s-urbaniak @squat

This is ready to be merged! :tada:

sliiiiiiiick!!! nice work! :+1:


[Question] DailyJob Exact

I'm planning to replace my current implementation of a daily job with the new helper class DailyJob.
I can see in your code that daily jobs cannot be exact (throw new IllegalArgumentException("Daily jobs cannot be exact, periodic or transient");) so I'm wondering if I pass the same argument for startMs and endMs will lead to any problem?
DailyJob.schedule(new JobRequest.Builder(TAG).setUpdateCurrent(updateCurrent),
                TimeUnit.HOURS.toMillis(hour),
                TimeUnit.HOURS.toMillis(hour));

Why didn't you try it yourself? It'll crash, you should provide a bigger time window instead.

Thanks, I asked because it didn't crash for me.

Really? I didn't add an explicit check. But I also don't have a strong opinion either. I thinking of leaving it as is.

Yes! So in the library logic a DailyJob cannot be exact event if I don't set the exact flag from the JobRequest builder and it should always be built with a time window bigger than 15 mins right?

Again, daily jobs can't be exact, but you can use the same argument for the start and end milliseconds parameters. The execution window for the daily job will be 0 milliseconds, but it's possible that the job will run a little earlier or later than the given time (depending on the system state). Does this answer your question?

Yes, thanks @vRallev! I'm closing this.

Also @vRallev  you can make a exact method in periodic too.. Sure it i will help people like me... I want to set alarms at 9am and 6pm everyday. So i don't need to set start and end time... Please consider... @aminezghidi  I am trying to set the same time for start and end in daily job... Will it work? Please help me with this


.NET 6 NullReferenceException

Describe the bug
The .NET 6 support was closed, so I'm not sure what the issue is. With .NET 6 brand new project, Intellisense is broken, I get errors and NullReferenceException:
[Error - 14.15.18] Request textDocument/codeAction failed.
  Message: System.NullReferenceException: Object reference not set to an instance of an object.
   at FsAutoComplete.CodeFix.Run.ifDiagnosticByType@176.Invoke(Diagnostic d) in D:\a\ionide-vscode-fsharp\ionide-vscode-fsharp\paket-files\github.com\fsharp\FsAutoComplete\src\FsAutoComplete\CodeFixes.fs:line 176
   at FsAutoComplete.CodeFix.Run.runDiagnostics@166-1.Invoke(Diagnostic d) in D:\a\ionide-vscode-fsharp\ionide-vscode-fsharp\paket-files\github.com\fsharp\FsAutoComplete\src\FsAutoComplete\CodeFixes.fs:line 166
   at Microsoft.FSharp.Collections.ArrayModule.Choose[T,TResult](FSharpFunc`2 chooser, T[] array) in D:\a\_work\1\s\src\fsharp\FSharp.Core\array.fs:line 478
   at FsAutoComplete.CodeFix.Run.runDiagnostics(FSharpFunc`2 pred, FSharpFunc`2 handler, CodeActionParams codeActionParams) in D:\a\ionide-vscode-fsharp\ionide-vscode-fsharp\paket-files\github.com\fsharp\FsAutoComplete\src\FsAutoComplete\CodeFixes.fs:line 165
   at FsAutoComplete.CodeFix.Run.ifDiagnosticByType@176-1.Invoke(CodeActionParams codeActionParams) in D:\a\ionide-vscode-fsharp\ionide-vscode-fsharp\paket-files\github.com\fsharp\FsAutoComplete\src\FsAutoComplete\CodeFixes.fs:line 176
   at FsAutoComplete.Lsp.TextDocumentCodeAction@1788-1.Invoke(Unit unitVar) in D:\a\ionide-vscode-fsharp\ionide-vscode-fsharp\paket-files\github.com\fsharp\FsAutoComplete\src\FsAutoComplete\FsAutoComplete.Lsp.fs:line 1790
   at Microsoft.FSharp.Control.AsyncPrimitives.CallThenInvoke[T,TResult](AsyncActivation`1 ctxt, TResult result1, FSharpFunc`2 part2) in D:\a\_work\1\s\src\fsharp\FSharp.Core\async.fs:line 446
   at Microsoft.FSharp.Control.Trampoline.Execute(FSharpFunc`2 firstAction) in D:\a\_work\1\s\src\fsharp\FSharp.Core\async.fs:line 104
  Code: -32603

Additionally I get error like this:
No .fsproj or .fsx file references c:\Source\FSharp\testgraphql\Program.fs
Steps to reproduce

Install .NET 6
Clone this: https://github.com/Ciantic/bug-fsharp-with-graphql
Open in VSCode

Expected behaviour
No errors, and intellisense works.
Machine info

OS: Windows
.NET SDK version: 6.0.10
Ionide version: 5.9.0

Other
The applications compiles and runs fine in Visual Studio as well as with dotnet run.
 dotnet --list-sdks
6.0.100 [C:\Program Files (x86)\dotnet\sdk]

dotnet --list-runtimes
Microsoft.NETCore.App 6.0.0 [C:\Program Files (x86)\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 6.0.0 [C:\Program Files (x86)\dotnet\shared\Microsoft.WindowsDesktop.App]

I can't reproduce this anymore, I have among other things installed .NET 5 SDK. When I could reproduce this I only had .NET 6 SDK installed.
Feel free to close this if it's not an issue, but perhaps NRE could be catched if it makes sense, and if someone else can reproduce this.

I'm experiencing the same issue, since I installed .NET 6 sdk Ionide stopped working completely.
Ionide Version 5.10.2

Ionide works just fine with .NET 6 - actually, it's the version we require for Ionide right now. Closing.


fix context

filter instance doesn't have access to gridOptionsWrapper
so need save link to context object

thanks. i've fixed this in my 'next release' branch.


Code Navigation issue when using PNPM workspaces

Actual Behavior
Hi. I have my project setup as a PNPM workspace and VSCode GraphQL has been working well except for 1 issue - It navigates within node_modules folder where PNPM has symlinked the file (as part of PNPM workspaces) instead of the actual file itself. I am adding a gif below demonstrating the same:

If you notice, the real fragment file is within sdk/fragments but it gooes inside node_modules and gets the same file from the symlinked node_modules folder.
Expected Behavior
Code navigation navigates to the real graphql file instead.
Specifications

GraphQL for VSCode Extension Version: v0.3.13
VSCode Version:

Version: 1.52.0-insider (user setup)
Commit: f4187f22026ff6537f2ca8132ad3209fceb5071f
Date: 2020-12-02T13:21:33.226Z
Electron: 9.3.5
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: <IP_ADDRESS>-electron.0
OS: Windows_NT x64 10.0.20201

OS: Ubuntu server 20.04

hmmm, will look into this, this may be baked into vscode though? or perhaps we need a path resolution to ignore symlinks somewhere

I had same problem and turns out problem wasn't with pnpm at all. Linking was all right the problem was the way vscode was interpreting it.
double-check your tsconfig.json, tsconfig.base.json. etc..
you shouldn't have
"preserveSymlinks": true,
according to tsconfig

With this enabled, references to modules and packages (e.g. imports and ///  directives) are all resolved relative to the location of the symbolic link file, rather than relative to the path that the symbolic link resolves to.