Tensorflow 1.8 graph destructor hanging indefinitely

I'm sorry to dump this on y'all on a weekend, but we're having strange problems with our CI when trying to upgrade to Tensorflow 1.8.
System information

Have I written custom code (as opposed to using a stock example script provided in TensorFlow):
OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Debian Stretch
TensorFlow installed from (source or binary): Binary (CPU wheel)
TensorFlow version (use command below): v1.8.0-0-g93bc2e2072
Python version: 3.6.6
Bazel version: n/a
CUDA/cuDNN version: n/a
GPU model and memory n/a

Exact command to reproduce: ... it's complicated
Describe the problem
When we run our test suite, it will intermittently hang (we've let it run overnight without any progress). We've traced this problem to TensorFlow 1.8 -- when we set TF_C_API_GRAPH_CONSTRUCTION=0, our test suite passes without problems and when we use Tensorflow 1.6 and 1.7, we don't seem to have any problems.
Unfortunately, I have not been able to create a minified, reproducible test case (it's also frustrating because I can't replicate this locally, despite using the same Docker image that our CI build is using). I have, however, been able to use Pyflame and gdb to grab stack traces (see https://gist.github.com/alanhdu/9ce45f9061a8e48ba2b0728489cb4ee7).
I think the relevant lines are:
/usr/local/lib/python3.6/site-packages/tensorflow/python/framework/c_api_util.py:__del__:50
/usr/local/lib/python3.6/inspect.py:getmodule:732
/usr/local/lib/python3.6/inspect.py:findsource:780
/usr/local/lib/python3.6/inspect.py:getframeinfo:1445
/usr/local/lib/python3.6/inspect.py:getouterframes:1471
/usr/local/lib/python3.6/inspect.py:stack:1494
/usr/local/lib/python3.6/site-packages/coverage/debug.py:short_stack:143
/usr/local/lib/python3.6/site-packages/coverage/collector.py:__init__:107
/usr/local/lib/python3.6/site-packages/coverage/control.py:_init:266
/usr/local/lib/python3.6/site-packages/coverage/control.py:load:675
/usr/local/lib/python3.6/site-packages/pytest_cov/embed.py:init:67
/usr/local/lib/python3.6/site-packages/pytest_cov/embed.py:multiprocessing_start:23
/usr/local/lib/python3.6/multiprocessing/util.py:_run_after_forkers:132
/usr/local/lib/python3.6/multiprocessing/process.py:_bootstrap:251
/usr/local/lib/python3.6/multiprocessing/popen_fork.py:_launch:73
/usr/local/lib/python3.6/multiprocessing/popen_fork.py:__init__:19
/usr/local/lib/python3.6/multiprocessing/context.py:_Popen:277
/usr/local/lib/python3.6/multiprocessing/process.py:start:105
/usr/local/lib/python3.6/multiprocessing/pool.py:_repopulate_pool:239
/usr/local/lib/python3.6/multiprocessing/pool.py:__init__:174
/usr/local/lib/python3.6/multiprocessing/context.py:Pool:119

which seems to be hanging at
#0  __pthread_cond_destroy (cond=0x56312aa153d0) at pthread_cond_destroy.c:76
#1  0x00007f6eef4deebb in tensorflow::thread::ThreadPool::Impl::~Impl() () from /usr/local/lib/python3.6/site-packages/tensorflow/python/../libtensorflow_framework.so
#2  0x00007f6eef4df89a in tensorflow::thread::ThreadPool::~ThreadPool() () from /usr/local/lib/python3.6/site-packages/tensorflow/python/../libtensorflow_framework.so
#3  0x00007f6eef87d665 in tensorflow::SingleThreadedCpuDevice::~SingleThreadedCpuDevice() ()
   from /usr/local/lib/python3.6/site-packages/tensorflow/python/../libtensorflow_framework.so
#4  0x00007f6eef87d85a in tensorflow::GraphRunner::~GraphRunner() () from /usr/local/lib/python3.6/site-packages/tensorflow/python/../libtensorflow_framework.so
#5  0x00007f6ef13e3aef in TF_DeleteGraph () from /usr/local/lib/python3.6/site-packages/tensorflow/python/_pywrap_tensorflow_internal.so
#6  0x00007f6ef1038784 in _wrap_TF_DeleteGraph () from /usr/local/lib/python3.6/site-packages/tensorflow/python/_pywrap_tensorflow_internal.so
#7  0x00007f6f4a6c78e9 in _PyCFunction_FastCallDict (func_obj=0x7f6ef4de69d8, args=0x7f6e84006730, nargs=<optimized out>, kwargs=kwargs@entry=0x0)
at Objects/methodobject.c:234

Do y'all happen to know what could have caused this error? Even tips on how to debug this would be super helpful.

Thank you for your post. We noticed you have not filled out the following field in the issue template. Could you update them if they are relevant in your case, or leave them as N/A? Thanks.
Bazel version
CUDA/cuDNN version
GPU model and memory
Exact command to reproduce

It has been 17 days with no activity and the awaiting response label was assigned. Is this still an issue?

@tensorflowbutler @tatatodd I believe I updated the issue with the relevant information. Let me know if you need any more information (or have something else you want to us to look at!).

@tatatodd I believe we are still having this problem (even with Tensorflow 1.10). Do you mind providing us any guidance on where to to start looking for the bug?

any update on this issue? I met the similar problem. multiprocessing + tensorflow 1.8. Hang in DeleteGraph

According to the comments of tf.Graph() constructor, it is not thread-safe. If you create one, you should delete it if it is useless before making new processes. Default graph is an exception, it is a property of current thread.

Nagging Assignee @tatatodd: It has been 14 days with no activity and this issue has an assignee. Please update the label and/or status accordingly.

Nagging Assignee @tatatodd: It has been 29 days with no activity and this issue has an assignee. Please update the label and/or status accordingly.

Nagging Assignee @tatatodd: It has been 44 days with no activity and this issue has an assignee. Please update the label and/or status accordingly.

Nagging Assignee @tatatodd: It has been 59 days with no activity and this issue has an assignee. Please update the label and/or status accordingly.

Nagging Assignee @tatatodd: It has been 74 days with no activity and this issue has an assignee. Please update the label and/or status accordingly.

Nagging Assignee @tatatodd: It has been 89 days with no activity and this issue has an assignee. Please update the label and/or status accordingly.

@alanhdu we see the PR https://github.com/hill-a/stable-baselines/pull/428 is merged  . please refer to the above comment https://github.com/tensorflow/tensorflow/issues/20600#issuecomment-416804754 and let us know if you still need any help here. If it is resolved then please feel free to move this issue to close status ? Thanks!


Deep stacks

Third time's the charm.

Not ready for review.

Ready to merge.

lazyand retval based deep stacks supported.
retval seems faster on one example.
Framework for adaptive deep stacks in place.


Updating for example branch

Updating readme from branch example
I updated readme file. Please review and accept.

##Thoughts
Hello. It is ok.  👍


feat(explore): default aggregate for string/numeric columns when creating metric

SUMMARY
When user creates a new adhoc metric with drag and dropping a column into metrics control, auto fill default aggregate in metric popover.
If column's generic type is numeric, set SUM aggregate as default.
if column's generic type is string or boolean, set COUNT_DISTINCT aggregate as default.
Otherwise, don't set a default aggregate.
Also, this PR fixes a bug metrics popover - when user created a metric with a custom label and then tried to create next metric, previous label was set instead of a default label. Now it should work as expected.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
https://user-images.githubusercontent.com/15073128/126321084-c75a8fc2-40fa-4d66-bf32-3be7eefa6f4d.mov
TESTING INSTRUCTIONS

Enable drag and drop feature flag
Drag numeric column to metrics control. The default aggregate should be SUM
Drag string or boolean column to metrics control. The default aggregate should be COUNT_DISTINCT
Drag other type of column to metrics control. Aggregate should be unset.
Click Run and make sure the metrics work properly
Edit the default label of some metric and then try to add a new one. A default label in the new metric popover should match column's name and selected aggregate. Previously set label shouldn't be shown here

ADDITIONAL INFORMATION

[ ] Has associated issue:
[ ] Changes UI
[ ] Includes DB Migration (follow approval process in SIP-59)

[ ] Migration is atomic, supports rollback & is backwards-compatible
[ ] Confirm DB migration upgrade and downgrade tested
[ ] Runtime estimates and downtime expectations provided

[ ] Introduces new feature or API
[ ] Removes existing feature or API

CC @junlincc

To fill up pre-aggregate function code look good to me.
the bug fix we should take more effect. When two metrics have the same name, I can't change one of the name.
https://user-images.githubusercontent.com/2016594/126329847-d6b7080f-e36b-4245-bfca-b5a855befb8f.mp4

the bug fix we should take more effect. When two metrics have the same name, I can't change one of the name.
duplicate.metric.mp4

Fixed, thanks for reporting! Can you take another look and verify?

I'll merge once @junlincc gives a green light - we need to decide if we need a feature flag and if we should replace COUNT_DISTINCT with COUNT.

LGTM. let's put the change behind an umbrella feature flag, e.g. UX_beta and set it to false by default.

/testenv up FEATURE_ENABLE_EXPLORE_DRAG_AND_DROP=true

"I don’t recommend doing count_distinct for string column. This is a precise deduplication operation. It is very resource intensive for the database. imagine, if this column has many values(high cardinality), this query can easily crash the database.  some databases have special functions to do this calculation."  @zhaoyongjie
I dont think this should be a concern. Even there's a preselected aggregate, users still need to click SAVE and RUN to run query that potentially crush anything. From UX standpoint, having a preselected aggregate has the equal amount of clicks to no preselected if users need to choose COUNT instead. and for most cases, count_distinct is indeed what users choose for STRING columns. I don't see any reasons why we should use COUNT as preselected.

@junlincc I added a UX_BETA feature flag, which is set to False by default


Default values for nested models

Hello community,
I can't seem to get default values working with nested models. Let me be more clear.
I have:
Note Model
   belongs_to :user, :inverse_of => :notes

User Model
   has_many :notes, :inverse_of => :user

RailsAdmin Configuration
config.model Note do
   edit do
      field :user do
         default_value do
            bindings[:view]._current_user
         end
    end
end

I have experimented with the following variations:
1- This works but displays integers instead of the model name
config.model Note do
   edit do
      field :user_id do
         default_value do
            bindings[:view]._current_user.id
         end
    end
end

2- This does not set any default value
config.model Note do
   edit do
      field :user_id do
         default_value do
            bindings[:view]._current_user
         end
    end
end

3- I also tried using enumerations instead of the default multi select but that didn't help either.
Any suggestions would be appreciated.
Thanks.

default value is not done in filtering_select widget. I don't think this will be too hard to implement.

Thanks for the reply.
I solved this issue by using a custom enumeration function in my model. In this function I use the options_for_select function's default value option so that RailsAdmin picks it up.
It's a bit of a workaround but it works nicely.


Fix loading templates in toolbar

Ref #2275
Checklist:

[x] Securely signed commits
[ ] Component(s) with PHPdocs
[ ] Unit testing, with >80% coverage
[ ] User guide updated
[x] Conforms to style guide

I took a different approach with https://github.com/codeigniter4/CodeIgniter4/pull/2280. I think either way is fine but I know there are other template references that are error if out than just these two.

Yes, I saw your PR after I submitted mine - sorry 😅
I didn't close this PR because I thought it's good to stay consistent with the files name convention across this module. So we should remove all .tpl.php and use .tpl everywhere or stay with what we have now - but it's just me.
I'm quite sure only these two caused problems... If there are still some errors then I can close this PR but I haven't spotted any so far.

I had issues with _database and _files both, so I think whatever we do we’ll need to give it all the same treatment.
I’m mobile now but I’ll think of a way to add tests for this and that might guide best practice.


fzf: fix patch for vim plugin; enable tests; avoid direct $src layout dependency

It was previously referencing $bin, but this package no longer produces a
bin output, just out and share. Updated to make the comparison check a bit
more robust.
Also updated to avoid direct dependency on the $src directory out of the nix
store, instead using the processed src setup in the unpackPhase. This provides a
cleaner abstraction between the build/install phase and the input src phase, and
avoids an unnecessary dependency on whether the source disted tarball comes from
fetchFromGitHub (in which case it's an unpacked directory) or something like
fetchurl. In either case, stdenv is responsible for processing the input src
and setting up a clean build dir for us, so we should use that.
This produces an equivalent directory tree, except that the vim plugin is no
longer broken.

Motivation for this change
Things done

[X] 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

[ ] 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)
[X] Ensured that relevant documentation is up to date
[X] Fits CONTRIBUTING.md.

@GrahamcOfBorg build fzf


FIXBUG: Storage medium cannot be changed to hdd when cool_down_time is reached

What type of PR is this：

[x] bug
[ ] feature
[ ] enhancement
[ ] others

Which issues of this PR fixes ：

Fixes #5231
Problem Summary(Required) ：

Change storage_medium to HDD instead of default_storage_medium when cool_down_time is reached.

[FE PR Coverage check]
:disappointed: fail : 0 / 2 (00.00%)
file detail

path
covered line
new line
coverage

:large_blue_circle:
com/starrocks/catalog/Catalog.java
0
2
00.00%


Better docs.

Here's the problem.  Why pulsar is better or at which tasks it is better?
Such high level brief actually proves two things:

author doesn't just write code - he actually solves problems and problems are specific
author understands the differences between his work and work of others in his field and is able to express that understanding as a comprehensible body of text

:+1:
I'd particularly love a comparison with Twisted and Tornado, both using the Reactor pattern

Better docs is not a valid issue, not in this project anyway.
A valid issue covers a specific area that a person can work on.
Writing better documentation is very important but it requires a joint effort of several people, especially people that are new and have not been involved in writing pulsar like myself.
Pulsar is opened source, if you need better docs, please feel free to help.
I have written pulsar because I needed to and I use it everyday to earn my living.
I didn't write it to prove anything.


auro-datepicker: setting minDate/maxDate does not update month navigation button visibility

Describe the bug
only setting the selected date triggers a call to assessNavigationButtonVisibility()
changing minDate or maxDate will not enable the calendar to reach those dates' months
To Reproduce
Steps to reproduce the behavior:
multicity search on https://www.alaskaair.com/search/
set 1st slice date and 2nd slice date to dates in the same month (e.g. Feb 2024).
then change the first date to something Jan 2024. open the datepicker for the second slice and you can't navigate to the previous month
Expected behavior
Setting the first slice date to 1/31/2024 should enable navigating to Jan 2024 for the second slice.
Screenshots

Desktop (please complete the following information):
this shouldn't depend on browser but i am using

OS: OSX
Browser: Chrome
Version:

Additional context
This can be worked around by also redundantly re-setting the selected date but I think it would be better to fix this in the component.

https://github.com/AlaskaAirlines/auro-datepicker/pull/167


Crash when moving with builder

When placing a non standard block like a bed or an block from enderio the game crashes.
crashreport

More info please. What exactly are you doing? What mode? What version of rftools?

Move option. 5.59. I see there is a newer version. Testing that now. More info when problem persists.

Tried with version 1.10-5.60
Trying to move this: a floor with 9 planks, a chest and a bed to here
Removed all other mods. new crashreport

Ok, I will check it out

I cannot reproduce this...

https://forum.feed-the-beast.com/threads/rf-tools-builder-block-crashing-game.258468/
I am having this same issue.

Thank you for taking the time to create this issue, as we're no longer supporting versions below 1.12, I'm going to go ahead and close it but if this bug seems to continue over to newer versions, please do report it again so we can investigate the issue further.


Air with dyn component

This change is

[!WARNING]
This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

#487  👈
#486
#484
#483
#482
#481
#480
#479
#478
#463
#477
#476
dev

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

Join @spapinistarkware and the rest of your teammates on  Graphite

Codecov Report
Attention: Patch coverage is 86.30137% with 10 lines in your changes are missing coverage. Please review.

Project coverage is 96.21%. Comparing base (9dbce2e) to head (74e5964).

Files
Patch %
Lines

src/core/air/component_visitors.rs
83.05%
10 Missing :warning:

Additional details and impacted files
@@                           Coverage Diff                            @@
##           spapini/03-15-clean_up_fri_quotients     #487      +/-   ##
========================================================================
+ Coverage                                 96.13%   96.21%   +0.08%
========================================================================
  Files                                        62       62
  Lines                                      8905     8783     -122
  Branches                                   8905     8783     -122
========================================================================
- Hits                                       8561     8451     -110
+ Misses                                      296      284      -12
  Partials                                     48       48

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.