JIT support [okina-jit]

Provides Just-In-Time feature for MFEM's kernels and functions.
Topic developed in CEED's milestone report ms37: "JIT in Applications at Scale".

Requirements

Works only when enabled through MFEM_USE_JIT.
MFEM shared library build (-fPIC) is now required and is turned on when MFEM_USE_JIT is selected.
Compiler & MPI agnostic: not tied to any frontend (clang), compiler, backends (nvrtc, hiprtc).

Overview
Lightweight solution, operating mostly at the kernel’s signature level, by adding extra MFEM_JIT attributes:

source-to-source approach, most work (hash) is done at compilation time:
An MFEM parser (mjit) is built to process selected *.cpp files: mass and diffusion in this PR.
It generates the code needed for the JIT compilation and cache libraries (libmjit.[a,so|dylib]) which are created as standard outputs of the current executable.

Allow runtime instantiation of non-templated code
Adding the MFEM_JIT keyword in front of kernels/arguments will trigger the code generation.
With the shared build enabled, there is no restriction on the kernels/functions: we can use the Device::*,      MemoryManager::* (Read/Write, etc.).

MFEM_JIT function signature
No specific requirements.
MFEM_JIT
void bbps(const size_t q, double *result,
          const MFEM_JIT int D,
          const MFEM_JIT size_t N){ ...

MFEM_JIT + MFEM kernel signature
Requires coupled T_D1D = 0 and d1d = 0, allows to use the same code w/ & w/o templates, w & w/o JIT.
MFEM_JIT template<int T_D1D = 0, int T_Q1D = 0>
void SmemPADiffusionApply3D(const int NE,
                            const bool symmetric,
                            ConstDeviceMatrix &b,
                            ConstDeviceMatrix &g,
                            DeviceTensor<5,const double> &D,
                            DeviceTensor<4,const double> &x,
                            DeviceTensor<4,double> &Y,
                            int d1d = 0,
                            int q1d = 0){ ...

System call
Recent version of MPI implementations usually claim that: In general, if your application calls system() or popen(), it will likely be safe. However, there are still some implementations that have limitations, depending if they rely on specific software or network stacks.
There are different ways to launch commands:

direct fork() and system() calls,
through the MPI_Comm_Spawn() interface,
by forking before MPI_Init and keeping one thread for the direct fork() and system() calls.

Both solutions 1 and 3. has been kept in this PR : 1 starts to be more widely supported and 3 ensures a better portability and does not require any additional MPI resources. 1 is the default and 3 can be selected at runtime with the MFEM_JIT_FORK environment variable set.
In the 3 case, only one extra process is created with OpenMPI, MPICH and MVAPICH2 MPI implementation.
The communication between the MPI root and its child is done in shared memory.
Parallel runs have been tested and validated with up to 32768 CPU MPI ranks and 1024 GPU MPI ranks.

This PR

~200loc JIT header + ~500loc to address unique "parallel" compilation & ~500loc for the parser
[ ] Decide which temporary directory to use (. for now)
[x] MFEM_JIT for specific #include headers
[ ] Revert tests/scripts/branch-history

Laghos demo
PR ready to try.

Removed features:

JIT support without -fPIC
Piped compilation with make
MFEM_TEMPLATE (as a function qualifier): transforms the function to a templated one, generating the instantiation table needed by the result of the cartesian product of the argument ranges.
MFEM_RANGE(...) (as an argument qualifier of a templated kernel): sets the argument range used while building the instantiation table.
MFEM_EMBED to embed some function into all following MFEM jited kernels.

PR
Author
Editor
Reviewers
Assignment
Approval
Merge

#719
@camierjs
@tzanio
@artv3 + @acfisher + @v-dobrev + @tzanio
8/16/22
⌛due 8/30/22
⌛due 9/6/22

PR Checklist

[x] Code builds.
[ ] Code passes make style.
[ ] Update CHANGELOG:

[ ] Is this a new feature users need to be aware of? New or updated example or miniapp?
[ ] Does it make sense to create a new section in the CHANGELOG to group with other related features?

[ ] Update INSTALL:

[ ] Had a new optional library been added? If so, what range of versions of this library are required? (Make sure the external library is compatible with our BSD license, e.g. it is not licensed under GPL!)
[ ] Have the version ranges for any required or optional libraries changed?
[ ] Does make or cmake have a new target?
[ ] Did the requirements or the installation process change? (rare)

[ ] Update continuous integration server configurations if necessary (e.g. with new version requirements for each of MFEM's dependencies)

[ ] .github
[ ] .appveyor.yml

[ ] Update .gitignore:

[ ] Check if make distclean; git status shows any files that were generated from the source by the project (not an IDE) but we don't want to track in the repository.
[ ] Add new patterns (just for the new files above) and re-run the above test.

[ ] New examples:

[ ] All sample runs at the top of the example source file work.
[ ] Update examples/makefile:

[ ] Add the example code to the appropriate SEQ_EXAMPLES and PAR_EXAMPLES variables.
[ ] Add any files generated by it to the clean target.
[ ] Add the example binary and any files generated by it to the top-level .gitignore file.

[ ] Update examples/CMakeLists.txt:

[ ] Add the example code to the ALL_EXE_SRCS variable.
[ ] Make sure THIS_TEST_OPTIONS is set correctly for the new example.

[ ] List the new example in doc/CodeDocumentation.dox.
[ ] If new examples directory (e.g.examples/pumi), list it in doc/CodeDocumentation.conf.in
[ ] Companion pull request for documentation in mfem/web repo:

[ ] Update or add example-specific documentation, see e.g. the src/examples.md.
[ ] Add the description, labels and screenshots in src/examples.md and src/img.
[ ] In examples.md, list the example under the appropriate categories, add new categories if necessary.
[ ] Add a short description of the example in the "Extensive Examples" section of features.md.

[ ] New miniapps:

[ ] All sample runs at the top of the miniapp source file work.
[ ] Update top-level makefile and makefile in corresponding miniapp directory.
[ ] Add the miniapp binary and any files generated by it to the top-level .gitignore file.
[ ] Update CMake build system:

[ ] Update the CMakeLists.txt file in the miniapps directory, if the new miniapp is in a new directory.
[ ] Add/update the CMakeLists.txt file in the new miniapp directory.
[ ] Consider adding a new test for the new miniapp.

[ ] List the new miniapp in doc/CodeDocumentation.dox
[ ] If new miniapps directory (e.g.miniapps/nurbs), add it to MINIAPP_SUBDIRS in the makefile.
[ ] If new miniapps directory (e.g.miniapps/nurbs), list it in doc/CodeDocumentation.conf.in
[ ] Companion pull request for documentation in mfem/web repo:

[ ] Update or add miniapp-specific documentation, see e.g. the src/meshing.md and src/electromagnetics.md files.
[ ] Add the description, labels and screenshots in src/examples.md and src/img.
[ ] The miniapps go at the end of the page, and are usually listed only under a specific "Application (PDE)" category.
[ ] Add a short description of the miniapp in the "Extensive Examples" section of features.md.

[ ] New capability:

[ ] All new public, protected, and private classes, methods, data members, and functions have full Doxygen-style documentation in source comments. Documentation should include descriptions of member data, function arguments and return values, template parameters, and prerequisites for calling new functions.
[ ] Pointer arguments and return values must specify whether ownership is being transferred or lent with the call.
[ ] Any new functions should include descriptions of their intended use e.g. for internal use only, user-facing, etc., along with references to example code whenever possible/appropriate.
[ ] Consider adding new sample runs in existing examples to highlight the new capability.
[ ] Consider saving cool simulation pictures with the new capability in the Confluence gallery (LLNL only) or submitting them, via pull request, to the gallery section of the mfem/web repo.
[ ] If this is a major new feature, consider mentioning it in the short summary inside README (rare).
[ ] List major new classes in doc/CodeDocumentation.dox (rare).

[ ] Update this checklist, if the new pull request affects it.
[ ] Run make unittest to make sure all unit tests pass.
[ ] Run the tests in tests/scripts.
[ ] (LLNL only) After merging:

[ ] Update internal tests to include the new features.

Will be re-opened when needed.

Should be ready to test and use.

This PR is now under review (see the table in the PR description). To help with the review process, please do not force push to the branch.

I build this branch using make serial MFEM_USE_JIT=YES and ran ex1. Is that all I need to get JIT working? I didn't see anything compile at run-time when I ran ex1 -o 4. Is there a way to check that we are compiling at run-time?

I build this branch using make serial MFEM_USE_JIT=YES and ran ex1. Is that all I need to get JIT working? I didn't see anything compile at run-time when I ran ex1 -o 4. Is there a way to check that we are compiling at run-time?

Compiling ex1, you should see the added -ldl: g++ -g -O3 -std=c++11 -I..  ex1.cpp -o ex1 -L.. -lmfem -ldl
and ex1 with the -pa option should trigger the JIT:
./ex1 -pa
Options used:
   --mesh ../data/star.mesh
   --order 1
   --no-static-condensation
   --partial-assembly
   --no-full-assembly
   --device cpu
   --visualization
Device configuration: cpu
Memory configuration: host-std
Number of finite element unknowns: 20801

MFEM Warning: [SmemPADiffusionApply2D<2,2,16>] g++ -g -O3 -std=c++11 -fPIC  -I /Users/camier1/home/sawmill/okina-jit/mfem/include/mfem -I /Users/camier1/home/sawmill/okina-jit -c -o k146701aa9a5dda2d.co k146701aa9a5dda2d.cc
 ... in function: static int mfem::internal::jit::System::Call(const char *, const char *)
 ... in file: general/jit/jit.cpp:253

ar: creating archive libmjit.a
Size of linear system: 20801

MFEM Warning: [SmemPADiffusionDiagonal2D<2,2,8>] g++ -g -O3 -std=c++11 -fPIC  -I /Users/camier1/home/sawmill/okina-jit/mfem/include/mfem -I /Users/camier1/home/sawmill/okina-jit -c -o kbc8d4214ab1edbea.co kbc8d4214ab1edbea.cc
 ... in function: static int mfem::internal::jit::System::Call(const char *, const char *)
 ... in file: general/jit/jit.cpp:253

   Iteration :   0  (B r, r) = 0.000387664
   Iteration :   1  (B r, r) = 0.0120978

I build this branch using make serial MFEM_USE_JIT=YES and ran ex1. Is that all I need to get JIT working? I didn't see anything compile at run-time when I ran ex1 -o 4. Is there a way to check that we are compiling at run-time?

Compiling ex1, you should see the added -ldl: g++ -g -O3 -std=c++11 -I.. ex1.cpp -o ex1 -L.. -lmfem -ldl
and ex1 with the -pa option should trigger the JIT:
./ex1 -pa
Options used:
   --mesh ../data/star.mesh
   --order 1
   --no-static-condensation
   --partial-assembly
   --no-full-assembly
   --device cpu
   --visualization
Device configuration: cpu
Memory configuration: host-std
Number of finite element unknowns: 20801

MFEM Warning: [SmemPADiffusionApply2D<2,2,16>] g++ -g -O3 -std=c++11 -fPIC  -I /Users/camier1/home/sawmill/okina-jit/mfem/include/mfem -I /Users/camier1/home/sawmill/okina-jit -c -o k146701aa9a5dda2d.co k146701aa9a5dda2d.cc
 ... in function: static int mfem::internal::jit::System::Call(const char *, const char *)
 ... in file: general/jit/jit.cpp:253

ar: creating archive libmjit.a
Size of linear system: 20801

MFEM Warning: [SmemPADiffusionDiagonal2D<2,2,8>] g++ -g -O3 -std=c++11 -fPIC  -I /Users/camier1/home/sawmill/okina-jit/mfem/include/mfem -I /Users/camier1/home/sawmill/okina-jit -c -o kbc8d4214ab1edbea.co kbc8d4214ab1edbea.cc
 ... in function: static int mfem::internal::jit::System::Call(const char *, const char *)
 ... in file: general/jit/jit.cpp:253

   Iteration :   0  (B r, r) = 0.000387664
   Iteration :   1  (B r, r) = 0.0120978

Thanks! I forgot to add -pa. I see it now. Super cool and easy to use!

Folks, this is an impactful change and we'd like to get more reviews on the PR.
Can you please take a look and let us know what you think?

@camierjs, can you please resolve the coflicts?

As discussed at the PR/technical meetings, I will remove the pipe compilation, revert to using the -fPIC, and reintroduce the sys::system direct calls.
The debug/breakpoint question and (JIT+AD) must be addressed as new requirements in order to meet the needs of the users, which will necessitate additional design iterations.

The pipe compilation was removed, MFEM_USE_JIT now requires an MFEM shared build allowing more latitude inside kernels, and std::system direct calls are also used by default with MPI.

We should add rm -rf libmjit* to the clean targets in examples/ and probably all other places where we build executables.

Some suggestions:

[ ] mention MFEM_USE_JIT in the INSTALL file

[ ] provide a simple example of how to build with it

for example: make config MFEM_USE_JIT=YES; make install; cd examples; make ex1; ./ex1 -pa
this could be either in INSTALL, make help or maybe general/jit/README.md?

[ ] consider adding make jit that will run make config MFEM_USE_JIT=YES; make install

The JIT compilation now shows as a warning, e.g.
MFEM Warning: [SmemPADiffusionDiagonal2D<3,3,8>] g++ -fPIC  -O3 -std=c++11  -I /Users/kolev1/mfem/mfem-porcelain/mfem/include/mfem -I /Users/kolev1/mfem/mfem-porcelain/mfem/include/mfem/fem -include "mfem.hpp" -include "general/forall.hpp" -include "general/jit/jit.hpp"  -c -o kd7cc67b126929f1d.co kd7cc67b126929f1d.cc
 ... in function: static int mfem::Jit::Run(const char *)
 ... in file: general/jit/jit.cpp:551

Can we show this only in DEBUG mode, and maybe have a simpler message (or no message) in the standard build?
Something like JIT: building SmemPADiffusionDiagonal2D<3,3,8> with g++...

Questions regarding the libmjit archive:

Is there an easy way to list the content of the archive, i.e. which functions have been JIT-ed?
Can I move the archive from one directory to another (e.g. from miniapps/solvers to examples)?
Can I combine the archives from different directories?

Running the tests with JIT enabled with CMake, I get some failures:
	  3 - sedov_tests_debug (Subprocess aborted)
	 13 - psedov_tests_debug_np=1 (Failed)
	 14 - psedov_tests_debug_np=4 (Failed)

It will be good to add at least one serial and one parallel test using examples/miniapps when JIT is enabled. For example, the tests can be to run ./ex1 -pa -no-vis and mpirun -np 4 ./ex1p -pa -no-vis while removing the JIT cache files right before each run. In addition, we can repeat the same run a second time -- this time it should reuse the JIT cache generated during the first run.

The JIT compilation now shows as a warning, e.g.
MFEM Warning: [SmemPADiffusionDiagonal2D<3,3,8>] g++ -fPIC  -O3 -std=c++11  -I /Users/kolev1/mfem/mfem-porcelain/mfem/include/mfem -I /Users/kolev1/mfem/mfem-porcelain/mfem/include/mfem/fem -include "mfem.hpp" -include "general/forall.hpp" -include "general/jit/jit.hpp"  -c -o kd7cc67b126929f1d.co kd7cc67b126929f1d.cc
 ... in function: static int mfem::Jit::Run(const char *)
 ... in file: general/jit/jit.cpp:551

Can we show this only in DEBUG mode, and maybe have a simpler message (or no message) in the standard build?
Something like JIT: building SmemPADiffusionDiagonal2D<3,3,8> with g++...

Questions regarding the libmjit archive:

Is there an easy way to list the content of the archive, i.e. which functions have been JIT-ed?

For now, this is not supported. Such feature could be possible through the mjit executable if we update such list each time the cache is updated.

Can I move the archive from one directory to another (e.g. from miniapps/solvers to examples)?

Yes, as long as it is the same installation that is used.

Can I combine the archives from different directories?

This is not yet supported too, but could be through mjit which could re-create the archives.

It will be good to add at least one serial and one parallel test using examples/miniapps when JIT is enabled. For example, the tests can be to run ./ex1 -pa -no-vis and mpirun -np 4 ./ex1p -pa -no-vis while removing the JIT cache files right before each run. In addition, we can repeat the same run a second time -- this time it should reuse the JIT cache generated during the first run.

done in https://github.com/mfem/mfem/pull/719/commits/b42a7be4b23c799715dd374bda8bb8e0f5d5c0fc


Store maps in a table, and add description support

This adds a global table NestMapsTable that holds all nest mappings (providing a base that future integrations can build off of), and adds very minimal support for descriptions (they can be added as a 3rd field and it won't cause an error, but no code makes actual use of it yet).
It's a decent first step to closing #4 I think.

Hey Corey. Thanks for the PR. I will start to review it once 1.1 is done - I am working on that right now.

I'm currently testing a super barebones which-key 'integration' in the form of require('which-key').register({ [mapConfig.lhs] = { mapConfig.description } }, { mode = sanitizedMode }) being included in the mode in string.gmatch(mergedPresets.mode, '.') for loop

I rebased my code off of (and changed the merge target to) master now that 1.1 is out, but I'll switch it to the 1.2 branch as soon as it's created.

@Corey-Keller I created a branch for 1.2 - lets rebase and PR targeting that branch for this feature. I will try to find some time this week to put some thought and feedback into it :-)

@LionC have you had a chance to look at/think about this yet? Not rushing/pushing you or anything (life always comes first), just wondering, in case it slipped your mind.

Looking at it now ;-)

So I looked at it and played around with it a bit. I took the liberty to modify the branch - I hope that is fine, as you marked it to be editable for maintainers.
Points behind the way I implemented it:

We do not need to rewrite the option merging logic - as we already have mergdPresets, we can just save thos
The whole feature should probably be optional, so I extracted it into a separate module that is set up in a way that makes it very easy to load it only on some .setup {} call. We should include such a call for a releasable version of the featur
That module should also (optionally) offer to register vim commands to open some UI to inspect the keymaps. I think this is also part of a minimal feature set to be releasable
I am unsure about the API. The current version just has a name which does not cascade and needs to be referenced explicitly. I do not know if I like the anonymous third string argument style yet, nor if I want names to cascade as a name prefix to allow DRYing up repetitive names (although I am not too sure how often that actually happens)

@LionC I'm getting errors like:
packer.nvim: Error running config for neogen: vim/shared.lua:205: invalid "behavior": table: 0x7ffbc971cf40
Error executing vim.schedule lua callback: vim/shared.lua:205: invalid "behavior": table: 0x7ffbc9b52258

Line 205 of $VIMRUNTIME/lua/vim/shared.lua is right before the vim.tbl_deep_extend function is defined, and I'm 99.9% sure it's due to the lack of a behavior (error/keep/force) in the vim.tbl_extend in inspect.saveMapping

@LionC I don't know about the 'name' cascading, since it's really just a descriptor for an individual mapping. I would however suggest cascading labels (like the "category" setting in nvim-mapper, but allowing for multiple, so that a mapping for some LSP functionality that takes a motion (like 3j) could have both the LSP and Motion labels).
I agree on not being sure about the API. You mention not being sure about using the 3rd anonymous argument, but I was just going along with the other 2 (which were also anonymous). The current method of 2 anonymous arguments, and 1 named seems really weird. Might be a good idea to make them all named explicitly.


Move description and depends to single line

@RackHD/corecommitters @RackHD/rackhd_dev

:+1:

:+1:


Python:stack_&_queue #552

Description 📜
Stacks and Queue data structured were documented and made available to the python branch in this fix. Coding is my motivation.
Fixes #552
Mentor @ankurg132

Type of change 📝

[x] Documentation (Content Creation in the form of codes or tutorials)

Domain of Contribution 📊

[x] Python

Checklist ✅

[x] I follow Contributing Guidelines & Code of conduct of this project.
[x] I have performed a self-review of my own code or work.
[x] I have commented my code, particularly in hard-to-understand areas.
[x] My changes generates no new warnings.
[x] I'm GWOC'21 contributor

Hey @bhumitbedse, can you also add the Stacks and Queue folder link in the readme for /python folder. Everything else looks good to me.

Hey @ankurg132, let me know if any changes required.

Please also fetch the latest commit and resolve the merge conflicts in the readme file.

Looks like there are no conflicts now. @adityabisoi you can merge this one!

Done


Invalid checksum error

Running the following code gives me an error that reads: 'Invalid checksum'. Code below:
var x = Address.addressToOutputScript("bc1qe43dk6yptz2e5aamxfc4sp33s6ga4v4xcrzhyv");

Does anyone know what this is?

This does not seem to give me an error when working with legacy addresses like: 18cBEMRxXHqzWWCxZNtU91F5sbUNKhL5PX.
Only seems to happen with P2WPKH addresses from what I can tell. If anyone has the fix to this but doesn't have the time to do it, let me know what exactly to do step by step and I'll try to get this done as it is quite urgent for me.

@RohanKapurDEV Which version are you using? Did you update the version ?.
I have nothing with the above code.
import 'package:dio/dio.dart';
import 'package:bitcoin_flutter/bitcoin_flutter.dart';

main() {
  var scriptPubKey = Address.addressToOutputScript('bc1qe43dk6yptz2e5aamxfc4sp33s6ga4v4xcrzhyv');
  print(scriptPubKey); ## [0, 20, 205, 98, 219, 104, 129, 88, 149, 154, 119, 187, 50, 113, 88, 6, 49, 134, 145, 218, 178, 166]
}

Yeah, my bad. It works fine! Thanks.


Mention arangodbtests (gtest) in README_maintainers.md

Does ./scripts/unittest all also run all gtest tests?
Should we mention Google Test and the arangodbtests binary in a separate section (own headline)?
Any noteworthy special features?

the tests binary is not built for production releases. Maybe we should mention that.

Added Willi's remark in https://github.com/arangodb/arangodb/commit/00967e4ceea1118f8d3d08631d5e2a72c173e7c5


Enhance UX design and UI elements

As a user, I want to feel that an application looks finished and well made, so that I can have more confidence in its results and a better user experience.
Definition of Done

[x] SDP Sticker is a pop up
[x] Dials do not turn too quickly or endlessly
[x] Buttons and text are styled
[x] The longer a +/- button is held, the faster it increases or decreases
[x] App visuals appear more polished
[x] Resizing objects is smoother and objects remain in their containers

Tasks

[x] #238
[x] #239
[x] #240
[x] #241
[x] #242
[x] #243
[x] #244
[x] #245
[x] #246
[x] #247
[x] #257
[x] #275

Stretch Goal Tasks

Add a 'Reset' button for clearing canvas instead of refreshing page (check w/ team first)
Refine dial element visual appearance

This story took me about 10.75 hours, a lot of which was troubleshooting related to the dial functionality:

1 hour on fixing our SDP sticker without using jquery
1 hour on disabling the dial turning if it's at its maximum or minimum value
3 hours on making the dial turn rate based on its maximum value and 360 degrees
40 minutes on styling every button on the page
1 hour on making sure all of the text on the page, including inside default buttons, was styled
1 hour on increasing the rate of the plus and minus buttons when held down
20 minutes on ensure the 'Save' button stays below the canvas
1.5 hours on shadow boxes because they initially broke the dials
20 minutes on finding and adding a background image
15 minutes on fixing a bug that was created by following linter requirements
40 minutes on moving, styling, and labeling the 'Zoom' plus and minus buttons


TypeError: Cannot read property '$$hashKey' of undefined

When using Previous States in combination with angular-permission I triggered an exception that required quite some debugging to figure out the root cause of. I'll share it here to spare your time if you're in the same situation. Perhaps there is also a way to make UI-Router Extras more robust (or forgiving).
Background
UI-Router-Extras decorate UI Router's $state.transitionTo
// Decorate $state.transitionTo.
$state.transitionTo = function (to, toParams, options) {

This part keeps a track of UI Router transitions. That data is then used when UI-Router-Extras catch UI Router's $stateChangeStart
$rootScope.$on("$stateChangeStart", function (evt, toState, toParams, fromState, fromParams) {
    var depth = transitionDepth;

So far, all in order.
Issue
Problems appear when you introduce angular-permission, which supports RBAC based on UI Router states.
But... angular-permission is also capturing the $stateChangeStart event and it has logic that prevents further propagation of as well as (re)transmitting the  $stateChangeStart event.
Result of this is that UI-Router-Extras can get "out of sync" with the states and you end up with:
2015-07-21T20:03:43.960+0200  TypeError: Cannot read property '$$hashKey' of undefined
    at baseExtend (https://localhost:4443/bower_components/angular/angular.js:413:14)
    at Object.extend (https://localhost:4443/bower_components/angular/angular.js:455:10)
    at https://localhost:4443/bower_components/ui-router-extras/release/ct-ui-router-extras.js:1689:35
    at Scope.$get.Scope.$broadcast (https://localhost:4443/bower_components/angular/angular.js:16149:28)
    at https://localhost:4443/bower_components/angular-permission/dist/angular-permission.js:58:29
    at processQueue (https://localhost:4443/bower_components/angular/angular.js:14551:28)
    at https://localhost:4443/bower_components/angular/angular.js:14567:27
    at Scope.$get.Scope.$eval (https://localhost:4443/bower_components/angular/angular.js:15830:28)
    at Scope.$get.Scope.$digest (https://localhost:4443/bower_components/angular/angular.js:15641:31)
    at Scope.$get.Scope.$apply (https://localhost:4443/bower_components/angular/angular.js:15935:24)

The exception above is triggered when the same $stateChangeStart event hits UI-Router-Extras' $stateChangeStart-event listener twice. My theory of the root cause:

UI Router broadcast a $stateChangeStart
UI-Router-Extras capture the $stateChangeStart event. All fine.
angular permission capture the $stateChangeStart event, blocks propagation and then does a retransmit (i.e. broadcast)
UI-Router-Extras capture the $stateChangeStart event again. Code breaks.

Versions:

angular-ui-router: 0.2.15
angular-permission: 0.3.1
ui-router-extras: 0.0.14

ran into the same issue... is there any workaround?

None that I’m aware of. I looked briefly into the possibility of controlling the order of event processing. If ui-router-extra would be ahead of angular permission when processing the events I think everything should work. I pretty soon took another route and I have now removed "previous states" from my code.

I had the same problem and after implementing platdesign's fix I have not seen that error anymore.

tentatively assigning 0.0.15 milestone

I looked at the angular-permission source code.  I don't think the $transition$ promise (and therefore also previous state) will be compatible with angular-permission.
The guard code in PR #230 isn't going to work because it corrupts the transition data stack (things won't get cleaned up properly).  I'm going to add a short circuit to that function.  It will render previous state mostly broken for transitions which angular-permission modifies, but shouldn't blow up.
I'll commit that "short circuit" code in a bit and build a 0.0.15-pre3 which I'd like you to try @goodies4uall @platdesign

This should be "fixed" (I added the guard code to at least stop the $$hashKey error from showing up).
Please try the 0.1.0-pre5 build found here: https://rawgit.com/christopherthielen/9c8775888f1650b7934d/raw/1c62623b591ec4dea80ba7674a8509e73cc83a64/ct-ui-router-extras.js

Issue is still reproducible.
Whenever I try to transition to state protected by a permission, the $$hashKey exception is always raised.
Versions:
angular-ui-router: 0.2.15
angular-permission: 0.3.1
ui-router-extras: 0.1.0-pre5

The $$hashKey error still pop up using ui router 0.1.0-pre5.
the error is triggered by this line, when depth = -1 and tDataStack.length = 0
Line 1724 var tData = angular.extend(tDataStack[depth], {
so I add another condition in the guard code:
Line 1720 if (transitionDepth >= tDataStack.length || transitionDepth === -1) return;
not sure of any side effects.
Waiting for comments
Versions:
angular-permission: 1.1.1
ui-router-extras: 0.1.0-pre5

Can you set up a demonstration plunk with extras and permissions for me? Use the released version of extras which is 0.1.0.

http://plnkr.co/edit/eSEzPS?p=preview
the error will happen when click the link

@christopherthielen the problem is here:
          $rootScope.$on("$stateChangeStart", function (evt, toState, toParams, fromState, fromParams) {
              if (transitionDepth >= tDataStack.length) return;
              var depth = transitionDepth;
              // To/From is now normalized by ui-router.  Add this information to the transition data object.
              var tData = angular.extend(tDataStack[depth], {
                to: { state: toState, params: toParams },
                from: { state: fromState, params: fromParams }
              });

              var restoreFn = decorateInjector(tData);
              restoreFnStack[depth] = restoreFn;
              $rootScope.$broadcast("$transitionStart", tData);
            }
          );

specially in line
var tData = angular.extend(tDataStack[depth], {

because depth is -1 and this value is out of the scope so to extend is passed an undefined. So if you would like to change here:
if (transitionDepth >= tDataStack.length) return;

to this:
if (transitionDepth >= tDataStack.length || transitionDepth < 0) return;

will work like a charm.
Best wishes for the New Year!

@christopherthielen will you check the solution above?

@christopherthielen bump

I will get to this when I have the time. I'd be happy to merge a PR

@christopherthielen PR is ready.


[Enhancement] Update UI to indicate that a click on a podcast's "+" is being processed

Clear and concise description of the problem
As a general principle it's nice to react to a click within a tenth of a second, but this is a specific case where I think it's a good first place to spend effort.
When searching for a podcast, I switch from "Home" to "Podcast" and then click the little "+" button. I then type some text, scroll through the resulting list, and then click one of their "+" icons.
The system appears to not do anything; but in fact the logs report than in the background it's searching, finding the podcast at a specific server, getting RSS, and downloading 4 most recent episodes. Meanwhile, the user has no affordance that anything is happening; they might click other "+" buttons, try the search again, reload, flip through pages, and at some point they'll suddenly notice that (apparently after all 4 episodes have downloaded) a podcast entry will appear -- if they wait long enough.
Suggested solution
The following two ideas could work independently or together.

Maybe replace the "+" button with an animation of a cycling circle? Or in some way indicate there's a recognition of the user's click. (This could in principle also apply when the user begins a search -- change the submit-button into an animation when a search is ongoing, and change it back into a search button once it's complete.)
Maybe dynamically update the podcast page as soon as data is available, allowing that to show in the background behind the search window.

Alternative
Providing a simple animated gif is good enough to let the user feel that their input worked, but more feedback is possible; an animated gif can be worse than nothing if the server crashes, leaving the gif "happily" spinning misleadingly. Progress bars or a little subwindow giving a general indication of the task that's currently being done can be both more reassuring and more informative.
Additional context
No response
Validations

[X] Follow our Code of Conduct
[X] Read the Contributing Guide.
[X] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.

Thanks for creating an issue. If you load the page do you see a Connected log in your browsers dev tools? When you click on the + icon it should start fetching the podcast. If it is fetched (takes normally less than a second) it should be added to the podcast screen immediately. When a podcast is downloaded and you are on the specific podcast page the cloud icon should be replaced by a play icon indicating a downloaded podcast episode.
Nevertheless I really need more animations. I'm going to add some loading icons when the user types and the query is sent to the server. Alerts are also on my ToDo list. Maybe a snack bar.

I can run docker-compose logs podfetch (or podgrab, I forget which, both names are present) on my server and see that as soon as I click, the search begins and everything else follows. Nothing gets added to any screen, including notifications, until all 4 episodes are finished downloading, though, at least not that I can see -- I've tried several times, and clicked around really hunting for them (of course I did this after having the idea of checking the logs, since otherwise I wouldn't have thought anything was happening, it takes a LONG time).

I meant the browser dev tools. You should have a message Connected in your browser console. Please check out the screenshot below.

Oh wow, your view of the page is impossible to reach from my system -- I can't actually see any episodes, only the tablet representing the podcast; I can click the star to make it a favorite but can do nothing else. I just assumed that listening to anything was a pending feature! I didn't know I was that badly broken.
 Is it possible I need to put a localhost address there instead, since I'm reverse-proxying?

Ah found the error. Put https://podfetch.tanksleyjr.us/ into SERVER_URL.

That's exactly what I had ... I copied and pasted it instead, just in case,
but it behaves the same.
-Wm
On Sat, Apr 1, 2023 at 8:42 AM SamTV12345 @.***> wrote:

Ah found the error. Put https://podfetch.tanksleyjr.us/ into SERVER_URL.
—
Reply to this email directly, view it on GitHub
https://github.com/SamTV12345/PodFetch/issues/31#issuecomment-1493012982,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJ7H6KWCGVAR65I6VFURRLW7BEEXANCNFSM6AAAAAAWPITJ6E
.
You are receiving this because you authored the thread.Message ID:
@.***>

Is the / really the last character in your SERVER_URL? The code joins SERVER_URL and /ws together. So if there is no slash at the end of the SERVER_URL the path gets added to the hostname.

I think you solved my problem, what's left to solve?
-Wm
On Sat, Apr 1, 2023 at 11:17 AM SamTV12345 @.***> wrote:

NPM stands for Nginx Proxy Manager - an interactivate Reverse Proxy with
built in Let's Encrypt Renewal. At least the site works for now. To dig
further into your problem I would need again the browser console output.
Could you please provide them? Which service are you using to expose
services to the internet behind Basic Authentication?
—
Reply to this email directly, view it on GitHub
https://github.com/SamTV12345/PodFetch/issues/31#issuecomment-1493065965,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJ7H6JA33VYBPY7542VWSTW7BWLTANCNFSM6AAAAAAWPITJ6E
.
You are receiving this because you authored the thread.Message ID:
@.***>

I though you had the problem that when you click the + icon the newly added Podcast is not added automatically and you need to refresh the page.

Oh, I see! Yes, that's right ... although now that I try it the problem's
worse... It doesn't do anything at all when I click "+", it doesn't even
show in the Docker logs. Wow, what did I do this time :) !
So I popped out the Console, and sure enough there's an immediate error
when I hit "+".
Of course, the problem here might be that the podcast in question is
passworded -- the 400 response kind of hints at that. But probably it
should at least log something.
It begins index-7a9ab748.js:100          POST https://podfetch.tanksleyjr.us/api/v1/podcast/itunes 400
...and then continues:
index-7a9ab748.js:100 Uncaught (in promise) ue {message: 'Request failed
with status code 400', name: 'AxiosError', code: 'ERR_BAD_REQUEST', config:
{…}, request: XMLHttpRequest, …}code: "ERR_BAD_REQUEST"config:
{transitional: {…}, adapter: Array(2), transformRequest: Array(1),
transformResponse: Array(1), timeout: 0, …}message: "Request failed with
status code 400"name: "AxiosError"request:
XMLHttpRequest {onreadystatechange: null, readyState: 4, timeout: 0,
withCredentials: false, upload: XMLHttpRequestUpload, …}response: {data:
'Json deserialize error: missing field `trackId` at line 1 column 12',
status: 400, statusText: '', headers: pl, config: {…}, …}stack:
"AxiosError: Request failed with status code 400\n    at r8 (
https://podfetch.tanksleyjr.us/ui/assets/index-7a9ab748.js:100:952)\n    at
XMLHttpRequest.p (
https://podfetch.tanksleyjr.us/ui/assets/index-7a9ab748.js:100:4051)"[[Prototype]]:
Error
Promise.then (async)
m @ Podcasts-ef19fff1.js:1
onClick @ Podcasts-ef19fff1.js:1
Ww @ index-7a9ab748.js:37
Gw @ index-7a9ab748.js:37
Jw @ index-7a9ab748.js:37
Up @ index-7a9ab748.js:37
nv @ index-7a9ab748.js:37
(anonymous) @ index-7a9ab748.js:37
o0 @ index-7a9ab748.js:40
kg @ index-7a9ab748.js:37
Gl @ index-7a9ab748.js:37
jd @ index-7a9ab748.js:37
f3 @ index-7a9ab748.js:37

... want me to expand any of those?
-Wm
On Sat, Apr 1, 2023 at 2:24 PM SamTV12345 @.***> wrote:

I though you had the problem that when you click the + icon the newly
added Podcast is not added automatically and you need to refresh the page.
—
Reply to this email directly, view it on GitHub
https://github.com/SamTV12345/PodFetch/issues/31#issuecomment-1493128458,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJ7H6OXJJQXUMGBQJIDA6TW7CMJBANCNFSM6AAAAAAWPITJ6E
.
You are receiving this because you authored the thread.Message ID:
@.***>

Oh, for authentication and reverse proxying I'm using "Caddy 2", I'm having
it do HTTPS and basic auth. It normally handles websockets in the same
config (it does for Audiobookserver, for example).
On Sat, Apr 1, 2023 at 11:17 AM SamTV12345 @.***> wrote:

NPM stands for Nginx Proxy Manager - an interactivate Reverse Proxy with
built in Let's Encrypt Renewal. At least the site works for now. To dig
further into your problem I would need again the browser console output.
Could you please provide them? Which service are you using to expose
services to the internet behind Basic Authentication?
—
Reply to this email directly, view it on GitHub
https://github.com/SamTV12345/PodFetch/issues/31#issuecomment-1493065965,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJ7H6JA33VYBPY7542VWSTW7BWLTANCNFSM6AAAAAAWPITJ6E
.
You are receiving this because you authored the thread.Message ID:
@.***>

Oh, I see! Yes, that's right ... although now that I try it the problem's worse... It doesn't do anything at all when I click "+", it doesn't even show in the Docker logs. Wow, what did I do this time :) ! So I popped out the Console, and sure enough there's an immediate error when I hit "+". Of course, the problem here might be that the podcast in question is passworded -- the 400 response kind of hints at that. But probably it should at least log something. It begins index-7a9ab748.js:100 POST https://podfetch.tanksleyjr.us/api/v1/podcast/itunes 400 ...and then continues: index-7a9ab748.js:100 Uncaught (in promise) ue {message: 'Request failed with status code 400', name: 'AxiosError', code: 'ERR_BAD_REQUEST', config: {…}, request: XMLHttpRequest, …}code: "ERR_BAD_REQUEST"config: {transitional: {…}, adapter: Array(2), transformRequest: Array(1), transformResponse: Array(1), timeout: 0, …}message: "Request failed with status code 400"name: "AxiosError"request: XMLHttpRequest {onreadystatechange: null, readyState: 4, timeout: 0, withCredentials: false, upload: XMLHttpRequestUpload, …}response: {data: 'Json deserialize error: missing field `trackId` at line 1 column 12', status: 400, statusText: '', headers: pl, config: {…}, …}stack: "AxiosError: Request failed with status code 400\n at r8 ( [https://podfetch.tanksleyjr.us/ui/assets/index-7a9ab748.js💯952)\n](https://podfetch.tanksleyjr.us/ui/assets/index-7a9ab748.js:100:952)%5Cn) at XMLHttpRequest.p ( [https://podfetch.tanksleyjr.us/ui/assets/index-7a9ab748.js💯4051)"[[Prototype]]](https://podfetch.tanksleyjr.us/ui/assets/index-7a9ab748.js:100:4051)%22%5B%5BPrototype%5D%5D): Error Promise.then (async) m @ Podcasts-ef19fff1.js:1 onClick @ Podcasts-ef19fff1.js:1 Ww @ index-7a9ab748.js:37 Gw @ index-7a9ab748.js:37 Jw @ index-7a9ab748.js:37 Up @ index-7a9ab748.js:37 nv @ index-7a9ab748.js:37 (anonymous) @ index-7a9ab748.js:37 o0 @ index-7a9ab748.js:40 kg @ index-7a9ab748.js:37 Gl @ index-7a9ab748.js:37 jd @ index-7a9ab748.js:37 f3 @ index-7a9ab748.js:37 ... want me to expand any of those?
…
-Wm
On Sat, Apr 1, 2023 at 2:24 PM SamTV12345 @.> wrote: I though you had the problem that when you click the + icon the newly added Podcast is not added automatically and you need to refresh the page. — Reply to this email directly, view it on GitHub <#31 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJ7H6OXJJQXUMGBQJIDA6TW7CMJBANCNFSM6AAAAAAWPITJ6E . You are receiving this because you authored the thread.Message ID: @.>

The problem is with the podcast feed. Which podcast do you want to download?

BTW this wasn't intended as a bug report, it was just suggesting a new
feature. It turns out I had a config bug :) .
Yup, agreed, the podcast I'd grabbed was defunct (I pulled something I'd
liked in the past, but it's dead now). (OTOH, add that to this feature
request -- getting an error probably shouldn't just sit there and look like
nothing happened.)
I tried "Brain Science Podcast", and it works -- in fact it draws the
podcast as soon as it downloads its first episode. It's still a delay, but
at least it doesn't take so long anymore.
On Sat, Apr 1, 2023 at 2:55 PM SamTV12345 @.***> wrote:

Oh, I see! Yes, that's right ... although now that I try it the problem's
worse... It doesn't do anything at all when I click "+", it doesn't even
show in the Docker logs. Wow, what did I do this time :) ! So I popped out
the Console, and sure enough there's an immediate error when I hit "+". Of
course, the problem here might be that the podcast in question is
passworded -- the 400 response kind of hints at that. But probably it
should at least log something. It begins index-7a9ab748.js:100 POST
https://podfetch.tanksleyjr.us/api/v1/podcast/itunes 400 ...and then
continues: index-7a9ab748.js:100 Uncaught (in promise) ue {message:
'Request failed with status code 400', name: 'AxiosError', code:
'ERR_BAD_REQUEST', config: {…}, request: XMLHttpRequest, …}code:
"ERR_BAD_REQUEST"config: {transitional: {…}, adapter: Array(2),
transformRequest: Array(1), transformResponse: Array(1), timeout: 0,
…}message: "Request failed with status code 400"name: "AxiosError"request:
XMLHttpRequest {onreadystatechange: null, readyState: 4, timeout: 0,
withCredentials: false, upload: XMLHttpRequestUpload, …}response: {data:
'Json deserialize error: missing field trackId at line 1 column 12',
status: 400, statusText: '', headers: pl, config: {…}, …}stack:
"AxiosError: Request failed with status code 400\n at r8 (
https://podfetch.tanksleyjr.us/ui/assets/index-7a9ab748.js💯952)\n%5Cn)
at XMLHttpRequest.p (
https://podfetch.tanksleyjr.us/ui/assets/index-7a9ab748.js
💯4051)"[[Prototype]]%22%5B%5BPrototype%5D%5D):
Error Promise.then (async) m @ Podcasts-ef19fff1.js:1 onClick @
Podcasts-ef19fff1.js:1 Ww @ index-7a9ab748.js:37 Gw @ index-7a9ab748.js:37
Jw @ index-7a9ab748.js:37 Up @ index-7a9ab748.js:37 nv @
index-7a9ab748.js:37 (anonymous) @ index-7a9ab748.js:37 o0 @
index-7a9ab748.js:40 kg @ index-7a9ab748.js:37 Gl @ index-7a9ab748.js:37 jd
@ index-7a9ab748.js:37 f3 @ index-7a9ab748.js:37 ... want me to expand
any of those?
… <#m_-1697000109958710349_>
-Wm
On Sat, Apr 1, 2023 at 2:24 PM SamTV12345 @.> wrote: I though you had
the problem that when you click the + icon the newly added Podcast is not
added automatically and you need to refresh the page. — Reply to this email
directly, view it on GitHub <#31 (comment)
https://github.com/SamTV12345/PodFetch/issues/31#issuecomment-1493128458>,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJ7H6OXJJQXUMGBQJIDA6TW7CMJBANCNFSM6AAAAAAWPITJ6E
https://github.com/notifications/unsubscribe-auth/AAJ7H6OXJJQXUMGBQJIDA6TW7CMJBANCNFSM6AAAAAAWPITJ6E
. You are receiving this because you authored the thread.Message ID: @.>
The problem is with the podcast feed. Which podcast do you want to
download?
—
Reply to this email directly, view it on GitHub
https://github.com/SamTV12345/PodFetch/issues/31#issuecomment-1493135316,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJ7H6PAZZUQLMMNOV7FMADW7CP4PANCNFSM6AAAAAAWPITJ6E
.
You are receiving this because you authored the thread.Message ID:
@.***>

Great that you could solve that issue. I will test this podcast tomorrow. The trackId of the Podcast should be a mandatory field but could be that it wasn't at that time. Parsing podcasts is really not funny as there are millions out there and it is hard to catch all variants. But good to have another sample to test out.
I will add more UI feedback next.
Having basic auth in the app was more important to me. Just merged the PR that solved the latter problem. It will take a bit until the latest tag is pushed again as the Raspberry PI has the Development build in its pipeline. So expect in the worst case 12 hours from now. You can then turn off Basic Auth in Caddy and turn that on in your docker-compose.

Cool, sounds like a good idea.
-Wm
On Sat, Apr 1, 2023 at 3:12 PM SamTV12345 @.***> wrote:

Great that you could solve that issue. I will test this podcast tomorrow.
The trackId of the Podcast should be a mandatory field but could be that it
wasn't at that time. Parsing podcasts is really not funny as there are
millions out there and it is hard to catch all variants. But good to have
another sample to test out.
I will add more UI feedback next.
Having basic auth in the app was more important to me. Just merged the PR
that solved the latter problem. It will take a bit until the latest tag is
pushed again as the Raspberry PI has the Development build in its pipeline.
So expect in the worst case 12 hours from now. You can then turn off Basic
Auth in Caddy and turn that on in your docker-compose.
—
Reply to this email directly, view it on GitHub
https://github.com/SamTV12345/PodFetch/issues/31#issuecomment-1493140378,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJ7H6J6QUJ53TGHLEJ5GZTW7CR6VANCNFSM6AAAAAAWPITJ6E
.
You are receiving this because you authored the thread.Message ID:
@.***>


Meeting Notes 2018-07-28

FYI: for all the watchers of this repo - @dingo-d and me had a video-chat meeting today about the progress of the project. This issue is just a short summary to keep people informed.
The open PRs were briefly discussed:

#10/ #124 @jrfnl is working on this, but the specs aren't clear. Will probably need a TRT decision.
#26 @jrfnl needs to go through the notes left by @grappler and will update the PR if necessary. Once that's done, the PR needs approval & merging.
#36 @grappler has an open PR for this upstream. Once the upstream PR has been merged, that should be added to the ruleset instead of merging this PR.
#76 @jrfnl will review the sniff as it is now.
This sniff should probably be pulled in WPCS upstream as well.
All the same, if the sniff is ready for TRTCS, it can be merged. Once it has been merged in WPCS and the minimum supported WPCSversion in TRTCS has gone up to the version in which the sniff was merged, the TRTCS version can be removed and the ruleset adjusted to use the upstream sniff.
#80 @grappler will need to check & decide what still needs to be done.
#104/ #122 @jrfnl will write a summary of the current problem with these PRs as an issue for the TRT to decide upon
#108/ #20 @dingo-d will write a summary of the current status of the PR as an issue for the TRT to decide upon.

De-forking the repo from WPCS
We discussed what steps are needed and what prerequisites need to be met/decisions need to be taken before this can be done.

An action list of what needs to be done can be found in #169.

@jrfnl will contact GH support about de-coupling this repo from WPCS.
A PR for this can be made relatively quickly, providing the necessary decisions are taken shortly.

The repo will need a new name which can also be used as a PHP namespace.
See issue #167 for the details of this discussion and please leave comments in that issue.
The sniffs can be categorized in the de-forked repo. We discussed the existing Theme sniffs and suggestions for categories to use.
See issue #166 for the details of this discussion and please leave comments in that issue.
Once the repo is de-forked, TRTCS can also have more rulesets.
See issue #168 for the details of this discussion and please leave comments in that issue.

Issues which need to be addressed by the TRT board, will be added to the agenda for the RT meeting of August 14.
The next (video)-chat about this repo will be Saturday August 18 16:00 CET.

Oh and what I forgot to mention:
Discussed WPCS 1.0.0

Talked through and merged PR #165 to update the TRTCS with the changes in WPCS.
Talked through a few new sniffs in WPCS 1.0.0 which could be interesting for TRTCS. Proposal to add these can be found in #170 and #171.


Remove unused link reference.

This was added by the PR I just approved, since I didn't want to wait another cycle between editing and reviewing when this PR would be faster to make.

cc @QuietMisdreavus or @steveklabnik for what should be a 5-second review.


Optimized for TypeScript

Hello,
Thank you for a wonderful extension.
I am making an application that reacts with TypeScript.
But, this extension is not optimized for TypeScript.
For example,
`` `
// js
import React from 'react'
/ / ts
import * as React from 'react'
`` `
I would like to fork this repository and create an extension optimized for TypeScript.
And I want to distribute it on the market.
(Of course I will follow LICENCE)
Is it OK?
Thank you for reading.

Hi :) No problem at all, you can fork and optimize this one for TS :)

Thank you!


feat: use VimEnter event instead of VeryLazy

Fixes #655.

A note, while the fix is correct, now the following comment is no longer correct:
  -- For example, in the following configuration, we use:
  --  event = 'VimEnter'
  --
  -- which loads which-key after all the UI elements are loaded. Events can be

Because VimEnter happens before UI.

Perhaps just change it to before all the UI elements are loaded

Good point 948004162ace7dba1df7fcce7b7fab1f3efd29f9

Thank you for your contributions everyone!


reports is not parseable as JSON via Javascript API

Judging from the a11y docs the following should be possible:
var a11y = require('a11y');
a11y("http://www.google.com", function (err, reports) {
    JSON.parse(reports);
});

However, this causes an error Unexpected token o.
Looking at the raw reports string it is not valid JSON - it's missing quotes around field names and also uses single-quotes; i.e.:
{ audit:
   [ { elements: '',
       heading: 'Audio elements should have controls',
       result: 'NA',
       severity: 'Warning' },
    ...]
}

Or am I missing something?

Doh. After delving into a11y I can see that it doesn't need JSON.parse at all - it's already an object. Not sure where I got the idea for JSON.parse from as I can't find it in the a11y docs now.
Sigh.


Readonly prop to textarea

Shot Type
Count
Status

Added
0
🟡

Deleted
0
❌

Regression
15
❗

❗ custom/widgets-collapsiblenavbar-opened__[w899px]_statistics_submenu (click to expand)

Before
After

❗ custom/widgets-meal-nutrients--hint-opened__[w1920px] (click to expand)

Before
After

❗ custom/widgets-trading-info-card--hover__[w1920px] (click to expand)

Before
After

❗ storybook/widgets-trading-info-card--default__[w1440px] (click to expand)

Before
After

❗ storybook/widgets-trading-info-card--default__[w1920px] (click to expand)

Before
After

❗ storybook/widgets-trading-info-card--default__[w390px] (click to expand)

Before
After

❗ storybook/widgets-trading-info-card--default__[w900px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--one-line__[w1440px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--one-line__[w1920px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--one-line__[w390px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--one-line__[w900px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--with-custom-component__[w1440px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--with-custom-component__[w1920px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--with-custom-component__[w390px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--with-custom-component__[w900px] (click to expand)

Before
After

Shot Type
Count
Status

Added
8
🟡

Deleted
0
❌

Regression
6
❗

🟡 storybook/components-textarea--disabled__[w1440px] (click to expand)

Image

🟡 storybook/components-textarea--disabled__[w1920px] (click to expand)

Image

🟡 storybook/components-textarea--disabled__[w390px] (click to expand)

Image

🟡 storybook/components-textarea--disabled__[w900px] (click to expand)

Image

🟡 storybook/components-textarea--read-only__[w1440px] (click to expand)

Image

🟡 storybook/components-textarea--read-only__[w1920px] (click to expand)

Image

🟡 storybook/components-textarea--read-only__[w390px] (click to expand)

Image

🟡 storybook/components-textarea--read-only__[w900px] (click to expand)

Image

❗ storybook/components-icons--icons__[w1440px] (click to expand)

Before
After

❗ storybook/components-icons--icons__[w1920px] (click to expand)

Before
After

❗ storybook/components-icons--icons__[w390px] (click to expand)

Before
After

❗ storybook/components-icons--icons__[w900px] (click to expand)

Before
After

❗ storybook/utility-responsive-image--responsive-image__[w1440px] (click to expand)

Before
After

❗ storybook/utility-responsive-image--responsive-image__[w1920px] (click to expand)

Before
After

Shot Type
Count
Status

Added
0
🟡

Deleted
0
❌

Regression
15
❗

❗ custom/widgets-collapsiblenavbar-opened__[w899px]_menu_opened (click to expand)

Before
After

❗ custom/widgets-collapsiblenavbar-opened__[w899px]_statistics_submenu (click to expand)

Before
After

❗ custom/widgets-trading-info-card--hover__[w1920px] (click to expand)

Before
After

❗ storybook/widgets-trading-info-card--default__[w1440px] (click to expand)

Before
After

❗ storybook/widgets-trading-info-card--default__[w1920px] (click to expand)

Before
After

❗ storybook/widgets-trading-info-card--default__[w390px] (click to expand)

Before
After

❗ storybook/widgets-trading-info-card--default__[w900px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--one-line__[w1440px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--one-line__[w1920px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--one-line__[w390px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--one-line__[w900px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--with-custom-component__[w1440px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--with-custom-component__[w1920px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--with-custom-component__[w390px] (click to expand)

Before
After

❗ storybook/widgets-trading-scoreboard--with-custom-component__[w900px] (click to expand)

Before
After

Shot Type
Count
Status

Added
0
🟡

Deleted
0
❌

Regression
0
❗

Shot Type
Count
Status

Added
0
🟡

Deleted
0
❌

Regression
0
❗

Shot Type
Count
Status

Added
12
🟡

Deleted
0
❌

Regression
0
❗

🟡 storybook/components-icons--icons__[w1440px] (click to expand)

Image

🟡 storybook/components-icons--icons__[w1920px] (click to expand)

Image

🟡 storybook/components-icons--icons__[w390px] (click to expand)

Image

🟡 storybook/components-icons--icons__[w900px] (click to expand)

Image

🟡 storybook/components-textarea--disabled__[w1440px] (click to expand)

Image

🟡 storybook/components-textarea--disabled__[w1920px] (click to expand)

Image

🟡 storybook/components-textarea--disabled__[w390px] (click to expand)

Image

🟡 storybook/components-textarea--disabled__[w900px] (click to expand)

Image

🟡 storybook/components-textarea--read-only__[w1440px] (click to expand)

Image

🟡 storybook/components-textarea--read-only__[w1920px] (click to expand)

Image

🟡 storybook/components-textarea--read-only__[w390px] (click to expand)

Image

🟡 storybook/components-textarea--read-only__[w900px] (click to expand)

Image

Shot Type
Count
Status

Added
0
🟡

Deleted
0
❌

Regression
3
❗

❗ custom/widgets-collapsiblenavbar-opened__[w899px]_statistics_submenu:

Before
After

❗ custom/widgets-meal-nutrients--hint-opened__[w390px]:

Before
After

❗ storybook/widgets-trading-scoreboard--with-custom-component__[w900px]:

Before
After

Shot Type
Count
Status

Added
0
🟡

Deleted
0
❌

Regression
2
❗

❗ custom/widgets-collapsiblenavbar-opened__[w899px]_statistics_submenu:

Before
After

❗ storybook/widgets-trading-scoreboard--with-custom-component__[w900px]:

Before
After


Make master service IP static (no longer randomly assigned)

Closes #2410
The master service currently does not select it's own internal service IP address. When the master service is created, it does not specify a PortalIP (see pkg/master/publish.go#L90), which causes ipAllocator to automatically select an internal IP address for the master service (see pkg/registry/service/rest.go#L94).
The SkyDNS service, which is started after the master, does select it's own internal service IP address, because it specifies the PortalIp in the service definition (see cluster/addons/dns/skydns-svc.yaml.in).
If the randomly assigned master service IP address happens to be the same as the statically assigned DNS IP address, the DNS service will fail to start.
To prevent this potential collision we modify the master service to specify a static IP address for itself (different from the DNS service's address).

Great points. Updated to generate two IP from portal_net subnet.
Sample (see PortalIPs):
{
  "kind": "ServiceList",
  "creationTimestamp": null,
  "selfLink": "/api/v1beta1/services",
  "resourceVersion": 80,
  "apiVersion": "v1beta1",
  "items": [
    {
      "id": "kubernetes-ro",
      "uid": "c86c77bb-a10e-11e4-b99b-42010af0067a",
      "creationTimestamp": "2015-01-21T01:42:39Z",
      "selfLink": "/api/v1beta1/services/kubernetes-ro?namespace=default",
      "resourceVersion": 4,
      "namespace": "default",
      "port": 80,
      "protocol": "TCP",
      "labels": {
        "component": "apiserver",
        "provider": "kubernetes"
      },
      "selector": null,
      "containerPort": 0,
      "portalIP": "<IP_ADDRESS>",
      "sessionAffinity": "None"
    },
    {
      "id": "kubernetes",
      "uid": "c8693400-a10e-11e4-b99b-42010af0067a",
      "creationTimestamp": "2015-01-21T01:42:39Z",
      "selfLink": "/api/v1beta1/services/kubernetes?namespace=default",
      "resourceVersion": 3,
      "namespace": "default",
      "port": 443,
      "protocol": "TCP",
      "labels": {
        "component": "apiserver",
        "provider": "kubernetes"
      },
      "selector": null,
      "containerPort": 0,
      "portalIP": "<IP_ADDRESS>",
      "sessionAffinity": "None"
    }
  ]
}

Ping

Feedback addressed. Changes squashed. PTAL.

Sorry for the noise, poke me when this last bit is undone and I'll final-review and commit ASAP.

Reverted PortalIP to net.IP change. PTAL.

2 nits and LGTM

Done and done.

PTAL

The logic around this is convoluted, and the documentation is worse.  We need to revisit what this is doing, what the flags are called and how they are documented.

  Sadly, we are out of hours and this will have to cook until Monday.  Committing on Friday evening is a sure fire way to have a bad weekend.
@a-robinson is oncall Monday, in case I forget to commit it myself.


Update to use RavenPy v0.8.0 and adjust documentation

Summary of changes

Updated from RavenPy v0.7.8 to v0.8.0
Dropped support for Python3.7 (same as in RavenPy)
Added rioxarray and ipywidgets to requirements (used explicitly in notebooks)
Removed a duplicated notebook (Extract_geographical_watershed_properties.ipynb) that was not in the existing documentation.
Set notebooks under docs/source/paper to be ignored.
Set ReadTheDocs to use mambaforge for installing dependencies (quicker/less memory intensive)
Set ReadTheDocs builds to "fail-on-warning"

Running into an issue due to settings in ReadTheDocs. Relevant information here: https://github.com/readthedocs/readthedocs.org/issues/9306

Running into an issue due to settings in ReadTheDocs. Relevant information here: readthedocs/readthedocs.org#9306

Oh they previously activate this conda update for us to ensure we use latest conda to have speed and memory optimization in latest conda.
Latest conda now not fast or use too much memory?  Have to switch to mamba?

Running into an issue due to settings in ReadTheDocs. Relevant information here: readthedocs/readthedocs.org#9306

Oh they previously activate this conda update for us to ensure we use latest conda to have speed and memory optimization in latest conda.
Latest conda now not fast or use too much memory? Have to switch to mamba?

Here is when that conda update is activated for Raven: https://github.com/readthedocs/readthedocs.org/issues/5847#issuecomment-519198831

Oh they previously activate this conda update for us to ensure we use latest conda to have speed and memory optimization in latest conda.

Ah! I forgot that was done on this repo/project. My bad!

Latest conda now not fast or use too much memory? Have to switch to mamba?

I figured why not have more synonymous buildouts for all of our documentation. It's not absolutely necessary, but it can't hurt?

Latest conda now not fast or use too much memory? Have to switch to mamba?

I figured why not have more synonymous buildouts for all of our documentation. It's not absolutely necessary, but it can't hurt?

Not hurt but I guess now you'll have to open an issue for RtD dev to disable that conda update flag for mamba to work.


Fixed minor eager-loading problem in show_observation.

This popped up during the flurry of PR merges.

Thanks Jason.
On Wed, Feb 23, 2022 at 5:38 PM Jason Hollinger @.***>
wrote:

Merged #873
https://github.com/MushroomObserver/mushroom-observer/pull/873 into
master.
—
Reply to this email directly, view it on GitHub
https://github.com/MushroomObserver/mushroom-observer/pull/873#event-6128418675,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAALDFDWHEQDMI6WJ6JYULTU4VOURANCNFSM5PFVZFSQ
.
You are receiving this because you are subscribed to this thread.Message
ID: <MushroomObserver/mushroom-observer/pull/873/issue_event/6128418675@
github.com>


[TASK]: small tweak to Show more / Show less button in caption blocks

I love the Show more / Show less button on caption blocks. A few small tweaks to make it less "loud", more perfect:

Reduce the font size to caption (12 px)
Reduce the padding
Left align it
turn off text-decoration so we don't see an underline on hover

Small update... make the padding-top: 4px instead of 2px as drawn. Thanks!


Add "rsort" filter and fix primitive array subscripting.

Add "rsort" filter to sort list items in the reverse order.
Update: I've noted the comment in the on the ignored test CoreFiltersTest#testSliceWithPrimitivesArray. The issue is located in GetAttributeExpression#evaluate. The initial implementation handles only array of references, in the second commit I modified it to handle arrays of any type and removed @Ignore so now all tests pass.

Thanks!


Make caching location optional.

Thanks for your great work!
Could this saving cache path be optional instead of always writes into /tmp/streaming ?
https://github.com/mosaicml/streaming/blob/cb8e872359643fa84782c4e95c496dc66e495c44/streaming/base/dataset.py#L515

Ah, you have a point there.
Would it be enough to use the official temp root of your operating system (say, os.path.join(tempfile.gettempdir(), 'streaming') IIRC?)
If not, what's your use case so we may better understand?

Hi @knighton. Thanks for your reply!
My working environment cannot access as root account.
If one of my partner runs your package first and somehow generates some cache files, such as /tmp/streaming/000000_barrier_filelock or /000000_locals, others could not access those files written under root directory.
Thus, PermissionError happens here.
Also, writing files under root directory is not allowed in my working space :(.
I have tried to modified self._filelock_root to my local directory under my account.
However, the process will stuck at the start of training.
So, I would like to ask if I coudl self._filelock_root. If so, what else should I modified? Thank you.

Hi @knighton.
I found another root path here:
https://github.com/mosaicml/streaming/blob/main/streaming/base/stream.py#L166
After modifying both self._filelock_root in dataset.py and root in stream.py, the scripts can successfully executed!
But I still want to confirm the correctness with you. Is there anything I need to change? Thank you.

Hi there!
The sharedmemory seems not be cleaned up successfully by the first or other users and then the error occurs: Permission denied: '/00000_locals'.
I also found another closed issue: https://github.com/mosaicml/streaming/issues/429 is the same issue I met here. But it seems not being solved.

After modifying both self._filelock_root in dataset.py and root in stream.py, the scripts can successfully executed!
But I still want to confirm the correctness with you. Is there anything else I need to change? Thank you.

I think you've fully gotten it (which is further supported by it running successfully), and also you are perfectly safe in making those changes you mentioned. Probably wise to have asked, as StreamingDataset has grown a bit complicated...
As you probably noticed, the temp root path in stream.py only comes into play when you do not provide local argument, letting it randomly generate a local for you.

The sharedmemory seems not be cleaned up successfully by the first or other users and then the error occurs: Permission denied: '/00000_locals'.

Leftover shared memory between runs that you have to clean up yourself is unfortunately something that happens when Python processes using shared memory die badly. We have gradually improved on this front over time, but it's far from solved completely. In the meantime, you can manually clear any stale shared memory objects by calling this method: https://github.com/mosaicml/streaming/blob/main/streaming/base/util.py#L169
If you meant you are already calling that method and encountering that permissions problem, that is all relating to the fact that Streaming was originally built to be run on ephemeral training jobs as root. On startup, StreamingDataset replicas do some registration and safety checks to prevent different runs clobbering the same dirs. Unfortunately, this was built for a world where everyone can write files to shared memory and these files can be read back by anyone.
As the original author of that difficult piece of nonsense, let me tell you that combined with patching filelock root, I think if you simply disable the checks and are just very careful about concurrent training jobs (and zombie processes thereof), you will be able to run this as non-root just fine.

Specifically, you could remove this bit of code: https://github.com/mosaicml/streaming/blob/cb8e872359643fa84782c4e95c496dc66e495c44/streaming/base/dataset.py#L509-L514
And replace it with something like
self._shm_prefix_int = 8  # I'm feeling lucky

If on Mac OSX, shmem paths need to be quite short. I believe Linux and the like are not so limited.

Hi @Skylion007. Thanks for your reply.
I haven't tried this to force destroy the leftover shared memory. If I encounter the same problem in the future, I will give it a try.
https://github.com/mosaicml/streaming/blob/main/streaming/base/util.py#L169
Now I can execute without shared memory permission denied issue that mentioned above by changing the constant names directly.. (for example: Add some ID to all the constants, like localsPW.)
Though its a very aggressive approach but it works...
If there are any risks with this approach, please let me know!
https://github.com/mosaicml/streaming/blob/main/streaming/base/constant.py
And thanks for the advice to remove code. I will try it.

Is your /tmp or equivalent directory world-readable and writeable? I'm thinking if we switched to files for registration and ensured 777 perms, it should be fine cross-user?

If there are any risks with this approach, please let me know!

You are clear.

For these path modification: Yes. My path is readable and writeable, and I can change the permission by chmod either.
https://github.com/mosaicml/streaming/issues/546#issuecomment-1868672842
As for /000000_locals issue, I failed to change the saving directory of shm (build from Python Multiprocessing), so I changed the saving name instead -> Change all the constant name by adding some ID that refers to me.


Git flow style helpers for continuous deployment

Hello,
I remember seeing a discussion about this topic, but don't remember where. It would be nice to support git flow development style.
Most of the time it works fine just the way it works now, but there are some corner cases that fail. I have encountered one of them in my continuous delivery pipeline.
The flow is like this:

master is latest production
develop is next version
Jenkins has jobs for building each of them
after the build is done, we push the artifacts into Sonatype Nexus: master pushes to releases and develop pushes to snapshots.
we have a policy of not allowing re-releases, meaning that you can't push the same final release twice

Once you've made a release, master and develop have the same commit with the release tag. What happens is that the develop branch gets the release version (since there are no ) and tries to push the same version on the release repo, which is forbidden.
While writing this I realized that I can probably work around this issue with a custom version strategy, but it would be nice to have it upstream.
I'll leave this here for future references.

Yeah, this is the general idea that #115 covers. I do want to support this, but it's a little tricky to think through and I haven't spent enough time on it yet.

FWIW, I'm doing the same thing.
I have a method that does the branching & version incrementing etc.
Ping me if you want more details.

@bedge ping ! :D

I have a couple of gradle files that exist in a subrepo of all my projects.
One handles the version number generation
The other does the branching and some tag cleanup work. It's quite crude and I haven't released it to QA yet, so I always do the branching for now. That said, it does save me from a lot of manual work.
It does have a problem in that the push doesn't work, so I ignore the error and push manually afterwards. There's an existing bug files on that already.
I'd appreciate any feedback/comments. I haven't had much time to work on these lately.
autoversioning.gradle:
ext.semanticVersion = SemanticVersion.from(version)
project.ext.'gradle.release.useAutomaticVersion' = 'true'
project.ext.releaseVersion=semanticVersion.releaseVersion()
def releaseType = System.getProperty("release.type", "")
project.ext.newVersion=semanticVersion.newVersion(releaseType)

class SemanticVersion {
	int major
	int minor
	int bugfix
	String extension

	SemanticVersion newVersion(String releaseType = "bugfix"){
        if(releaseType == "major"){
            return new SemanticVersion(major:major+1, minor:0, bugfix:0, extension:"SNAPSHOT")
        }else if(releaseType == "minor"){
            return new SemanticVersion(major:major, minor:minor+1, bugfix:0, extension:"SNAPSHOT")
        }else{
            return new SemanticVersion(major:major, minor:minor, bugfix:bugfix+1, extension:"SNAPSHOT")
        }
    }

	public static SemanticVersion from(String versionString){
		def splitted = versionString.split('[\\.-]')
		return new SemanticVersion(major: Integer.parseInt(splitted[0]),
								   minor: Integer.parseInt(splitted[1]),
								   bugfix: Integer.parseInt(splitted[2]),
								   extension: splitted.length != 4 ?: splitted[3])
	}

	public SemanticVersion releaseVersion(){
		if(extension==null){
			return this
		} else {
			return new SemanticVersion(major:major, minor:minor, bugfix:bugfix, extension:"SNAPSHOT");
		}
	}

	String toString(){
        "${major}.${minor}.${bugfix}${extension ? '-' + extension.toString() :''}"
    }
}

gitranch.gradle:
import org.ajoberstar.grgit.*
import org.ajoberstar.grgit.operation.*

buildscript {
	repositories {
		mavenCentral()
	}
	dependencies {
		classpath("org.springframework.boot:spring-boot-gradle-plugin:1.3.0.RELEASE")
		classpath 'org.ajoberstar:gradle-git:1.4.2'
	}
}

release {
	git {
		requireBranch = 'develop'
	}
}

task releaseHelp() {
	group = "Help"
	description = "(nim) Show details of release options"
	doLast {
		println "Release options:"
		println "eg: gradle release -Drelease.type=minor, -Drelease.name=filbert"
		println "=<major|minor|patch>, determines how to increment version number."
		println "-Drelease.name=<string>, Name to use for new release branch."
		println "Pass above options to see generated version number."
		def releaseType = System.getProperty("release.type", "")
		if( releaseType != null && releaseType.size() > 0 ) {
			println "Old: ${version} -> New: ${project.ext.newVersion}"
		}
	}
}

task checkReleaseTag() {
	group = "Debug"
	description = "(nim) Dump tags - no impact"
	doLast {
		def repo = Grgit.open(project.file('.'))
		def tags = repo.tag.list()
		println "checkReleaseTag: version=${version}"
		tags.each() { tag ->
			println("tagName=${tag.getFullName()}")
		}
	}
}

createReleaseTag.dependsOn preTagCommit

task createReleaseBranch() {
	group = "Release"
	description = "(nim) Create branch (-Drelease.name=<name>) from current develop head with push"
	doLast {
		def release = System.getProperty("release.name")
		if (null == release) {
			throw new GradleException("-Drelease.name=.. missing.")
		}
		def releaseBranchName = "release/${release}"
		println "release branch name = ${releaseBranchName}"
		def repo = Grgit.open(project.file('.'))
		def branchService = repo.getBranch()
		def developBranch = branchService.getCurrent()
		def branchStatus
		try {
			branchStatus = branchService.getStatus(name: "release/${releaseBranchName}")
			throw new GradleException("Branch ${releaseBranchName} already exists.")
		}
		catch(Exception e) {}	// Expect that branch does not already exist.
		println "About to create branch"
		branchService.add(name: releaseBranchName, startPoint: 'develop', mode: BranchAddOp.Mode.TRACK)
		println "Branch created: ${releaseBranchName}, next push"

		// Allow the use of -Dforce=1 to ignore the push error.
		// This lets the developer manually push the repo
		// See https://github.com/ajoberstar/gradle-git/issues/145
		def force = System.getProperty("force")
		if(force == null || force.isEmpty()) {
			repo.push(all: true)
			println "Push OK"
		}
		else {
			println "force push enabled, errors ignored."
			try {
				repo.push(all: true)
				println "Push OK"
			}
			catch(Exception e) {
				// See https://github.com/allegro/axion-release-plugin/issues/66
				println "Repo push failed, execute manually. This is usually needed from jenkins."
			}
		}
	}
}

task reanmeDevelopTags(dependsOn: createReleaseBranch) {
	group = "Release"
	description = "(nim) Rename develop tags into release tags"
	doLast {
		def release = System.getProperty("release.name")
		if (null == release) {
			throw new GradleException("-Drelease.name=.. missing.")
		}
		def developToken = "build-develop"
		def releaseReplacement = "build-release_${release}"
		def repo = Grgit.open(project.file('.'))
		def tags = repo.tag.list()
		println "renameDevelopTags, release=${releaseReplacement}"
		try {
			tags.each() { tag ->
				String tagName = tag.getFullName()
				if(tagName.contains(developToken)) {
						String tagNewName = tagName.replace(developToken, releaseReplacement)
						Tag newTag = repo.tag.add(name: tagNewName, pointsTo: tag)
						repo.tag.remove(names: [tagName])
						println "Renamed tag ${tagName} -> ${tagNewName}"
				}
			}
		}
		catch(Exception e) {
			println "Tag copy failed. Can happen is release is performed more than once."
		}
	}
}

updateVersion.dependsOn reanmeDevelopTags

I'll close this since #115 is still around to cover this.


Passing in test files to CLI should be matched against relative path

🚀 Feature Proposal
When running jest foo, foo should be matched against the path relative to package.json instead of its absolute path.
Motivation
We have a test file user.spec.ts, and accidentally running jest user runs all tests, because the full path of all the test files starts with /Users/my-username/.... It's also odd to run jest foo and not see the string "foo" anywhere in the output
$ jest test /Users

RUNS src/index.spec.ts
RUNS src/author.spec.ts
RUNS src/book.spec.ts

Example

Pitch
This oddity is confusing behavior that should at least be documented. The current documentation says

When you run jest with an argument, that argument is treated as a regular expression to match against files in your project.

which is confusing if the regular expression can also match directories outside of my project. I can't think of a good reason to keep this behavior (why would you want a regex matching all of the test files in your project?)

Key location to edit seems to be here: https://github.com/facebook/jest/blob/504cacee18b844a974e76e5c45b2568bf023d3ac/packages/jest-core/src/SearchSource.ts#L296-L300

To be fair, Jest at least consistently does this (resolving to absolute paths) pretty much anywhere we use paths.
I regularly use it to match only a test.js I've created in the root by including the project directory name (jest my-project/test.js) however this could also be achieved in relative path matching.
I would say https://github.com/facebook/jest/issues/7185 is the place to do such a change if we want if that ever happens - if we switch all paths to glob matching by default, those globs can also be relative to the cwd in CLI arguments, or root dir in config files.

I still think this would be good to fix

I'd honestly consider this a bug. We need to work if you pass an absolute path, but we should probably special case absolute paths instead. Matching on patterns outside of rootDir is just weird.
Is this something you'd be willing to work on?

https://github.com/jestjs/jest/releases/tag/v30.0.0-alpha.1
finally! 😅


Dockerfiles: Use JSON for linter ENTRYPOINT.

This will avoid having a warning printed when we use the linter.

Could you link to which warning message you mean?
If you mean https://github.com/inspektor-gadget/inspektor-gadget/actions/runs/9892901123/job/27326739167 (from this PRs CI run) it is not resolved


F7MessageBar undefined $ref.textarea

My code:

<f7-page>
    <f7-messages>
        <f7-message v-for="message in messages"
                    :key="message.text"
                    :text="message.text"
                    :type="message.type"></f7-message>
    </f7-messages>
    <f7-messagebar send-link="Enviar" @submit="onSend"></f7-messagebar>
</f7-page>

When I click on send button it shows this error:
[Vue warn]: Error in event handler for "click": "TypeError: Cannot read property 'value' of undefined"
found in
---

 at src\pages\chat.vue

 at src\app.vue

I checked the source code and my guess is that $refs.area is undefined
onClick(event) {
    const value = this.$refs.area.value;
    const clear = this.f7Messagebar ? this.f7Messagebar.clear : () => {};
    this.$emit('submit', value, clear);
    this.$emit('send', value, clear);
    this.$emit('click', event);
},

I also got this error, how can I fix it？ Thanks.

I fixed it by copying his component to a new component made by me, and then
I fixed the errors.
I don't remember what I did, but it didn't take too much
El jue., 20 sept. 2018 a las 3:53, lenLch<EMAIL_ADDRESS>escribió:

I also got this error, how can I fix it？ Thanks.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/framework7io/framework7-vue/issues/344#issuecomment-423013576,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AN5Z3BLQphjpC8r5iAybumrdmtNkJ_U4ks5ucvUDgaJpZM4R1i3A
.


Added missing Openshift link

Description

Added missing Openshift link
Todos

[ ] Tests
[ ] Documentation
[ ] Release note

Release Note

None required

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

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

This is really great @ToroNZ . The only issue is that the link does not seem to work correctly. However, we are missing this so if you can add a link that passes htmlproofer it will be nice to merge this.

@emanic - Hopefully I've done it properly now :). Built it locally in my machine and seems to be working as expected. Cheers

Great thank you @ToroNZ ... any chance you could squash your commits, we would love to merge this 👍

Please refer to #1522


Error when reading .wav files using TPU

Please make sure that this is a bug. As per our
GitHub Policy,
we only address code/doc bugs, performance issues, feature requests and
build/installation issues on GitHub. tag:bug_template
System information

Have I written custom code (as opposed to using a stock example script provided in TensorFlow): Yes
OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Colab

Describe the current behavior
I am trying to read .wav files in my input pipeline and train on TPU. I am using tfio.audio.AudioIOTensor but it is not working with TPU.
Here is a colab that shows the error:
https://colab.research.google.com/drive/1gSP3bhmDkMFwHwxWWc3B3hdR9SNA0hM9#scrollTo=FItPzgJ1xJzZ
The error is the following:
NotFoundError: Op type not registered 'IO>AudioReadableInit' in binary running on n-6a025964-w-0. Make sure the Op and Kernel are registered in the binary running in this process. Note that if you are loading a saved graph which used ops from tf.contrib, accessing (e.g.) `tf.contrib.resampler` should be done before importing the graph, as contrib ops are lazily registered when the module is first accessed. [Op:BatchDatasetV2]

Is there another way to decode .wav files when using TPU?

@invoxiaglo
Please refer to this link and let us know.
You can use tf.audio.decode_wav,it is part of tensorflow and will eliminate tfio, avoiding the error faced.


ARC/BRD Does not use abilities granted by Hawk's Eye buff

ARC/BRD Does not use abilities granted by Hawk's Eye buff such as Straight Shot, Refulgent Arrow, Wide Volley or Shadowbite.

This is a big deal. Bard is almost in auto shot mode as it currently is. StraightShotReady was replaced with Hawk's Eye

Looks like Barrage ability is not properly recognized as even after unlocking the ability, it is not being used and System Warnings keeps repeating that the ability needs to be unlocked.

fixed


increase maxConnections from one to six

This commit changes the default value from one to six as six
is a more sane default value, even if it could be too much in
certain legacy browsers.

Please amend the commit as this is more like a feature feat


MGMT-15798: Upgrade to ubi9 base image in order to have patched glibc package

Upgrade to ubi9 base image in order to have patched glibc package

/cc @rccrdpccl

/lgtm
/approve


Importing fails on PHP7

I was using this plugin to add and remove entries for a while but when I upgraded a server to PHP 7.0.12 it started having issues. When importing a CSV the task will occasionally get stuck so I have to remove the stuck task then reimport the CSV and removing entries with a CSV doesn't work at all anymore. After downgrading to PHP 5.6.28 everything works again as expected.

I was using an older version of the plugin. Updating to the latest version fixed this issue.


feature: cache sounds

I would suggest caching the sound effect after the first request.
This will prevent the browser from loading the file more than one time.

As you can see, I hovered the logo and the sound file got downloaded on every event.

hmmmm, how do you cache sounds?

onhover (look in array for filename)
  if (not exists)
    load sound
    add filename to array
    play sound
  otherwise
    play sound

This would be solved by the method I mention under #2

+1


Feat/fa locale

Hi @masihjahangiri, a big thank you for raising the PR.
Please help take care of following points:

Use the format of language code and country code for naming the locale file. e.g. en-US
Add unit tests.
Use npm instead of yarn

Thanks @mastermunj. I fixed your points. please review again.

@mastermunj Thanks for make this elegant library. May you review my MR to add Fa language to your package.

Hi @masihjahangiri, I am making changes in code to include several of Indian languages, however, I am not having challenge understanding the code you wrote for fa-IR locale.
I need your help in understanding the change you made and how the number system there works so that it becomes easier for me to navigate through the code for making the changes I need to make.

Hi, @mastermunj sure. How can I help you?

I'd appreciate if you can elaborate the changes done here.
Also, the logic behind adding options and decimalLengthWordMapping here.


fix: Slack link expired

Solves the issue #113

LGTM but we can't merge yet because of (presumably) some unrelated issue we have with the Vercel builds. See https://github.com/elixir-cloud-aai/cloud-components/issues/240

@uniqueg, I'd like to discuss the "Dashboard Web Components (React, Vue, etc.) for file upload and handling" project with you. I attempted to contact you on Slack. I understand you might be busy, but could you please let me know how I can reach you to discuss this? Alternatively, if you're unavailable, could you direct me to someone who can assist with this matter? Thank you.

@uniqueg, I'd like to discuss the "Dashboard Web Components (React, Vue, etc.) for file upload and handling" project with you. I attempted to contact you on Slack. I understand you might be busy, but could you please let me know how I can reach you to discuss this? Alternatively, if you're unavailable, could you direct me to someone who can assist with this matter? Thank you.

@psankhe28, thanks for the PR, will merge it! Please join the Slack channels and the biweekly OSS meeting on 18/03 for project-related queries.

@uniqueg, I'd like to discuss the "Dashboard Web Components (React, Vue, etc.) for file upload and handling" project with you. I attempted to contact you on Slack. I understand you might be busy, but could you please let me know how I can reach you to discuss this? Alternatively, if you're unavailable, could you direct me to someone who can assist with this matter? Thank you.

@psankhe28, thanks for the PR, will merge it! Please join the Slack channels and the biweekly OSS meeting on 18/03 for project-related queries.

Yes, I have joined the slack channel. I will join the biweekly OSS meeting too. Thanks!


Improved Button Responsiveness and Layout Adjustments

Proposed Changes

Fixes #9156

here i changed the hap between the red button and green oulined button
Change 2
-
here i changed the responsive-ness wrap
Change 3

here i improved the responsive ness of the buttons by align to center
Change 4

here i changed it level
Change 5

here i changed it level
@ohcnetwork/care-fe-code-reviewers

Merge Checklist

[ ] Add specs that demonstrate bug / test a new feature.
[ ] Update product documentation.
[ ] Ensure that UI text is kept in I18n files.
[ ] Prep screenshot or demo video for changelog entry, and attach it to issue.
[ ] Request for Peer Reviews
[ ] Completion of QA

Summary by CodeRabbit
Release Notes

New Features

Enhanced layout for various components, improving user interface consistency and responsiveness.
Added conditional checks for user roles in patient management, ensuring appropriate access to functionalities.
Introduced a confirmation dialog for changing patient code statuses in consent records.

Bug Fixes

Improved handling of existing consent records during file uploads to prevent errors.

Style

Updated spacing and layout styles across multiple components for better visual presentation, including improved button spacing and alignment adjustments.

@gurramkarthiknetha Bro, this is the 4th one 😅  As I've mentioned before, please update the original PR instead of opening new ones.
#9161 is the original.

@gurramkarthiknetha Bro, this is the 4th one 😅 As I've mentioned before, please update the original PR instead of opening new ones.
#9161 is the original.

it's ok


Event Card Animation doesn't occur

The slideup animation of events doesn't occur

Working on it :+1:

please attach a gif of what you are trying to say


make check_key_press function unsafe

https://github.com/etra0/botw-freecam/blob/5129e21902336ae8555cdcae231a15655201a249/botw-freecam/src/utils.rs#L49-L51
hello, if a function's entire body is unsafe, the function is itself unsafe and should be marked appropriately. Marking them unsafe also means that callers must make sure they know what they're doing.

Although GetAsyncKeyState is an unsafe function, according to Microsoft docs there's no remark that the function could crash or corrupt anything, and I'm pretty sure that's a battle tested API, too.
And to be honest, I wasn't very careful on marking unsafe/safe functions, I should, in the future, but for now, I think it's ok, since we're building an app and not a library.
Thanks for pointing it out, though!


[ServiceBus] bump runtime dependency core-amqp version to ^4.1.1

This ensures we can use the newly added constants maxUint32Value

API change check
API changes are not detected in this pull request.


Bootstrap 4 Modal (modal-backdrop) don´t close in Google chrome 72

Modal in bootstrap 4.1.3 don´t close the  . Even on the official bootstrap site the demo don´t close on google chrome 72. So the screen stays greyed..

Works fine here. We need more info.

I got the problem. Was an extension for google called Keyboard
ID: aebnnochodigmgkihkmadggmbncnahen
I turned this off and modals works fine. Thanks a lot for the fast reply..


af.info() in the wrong window

Hello,
That is just a minor bug, but it can be disturbing.
When you are using spyder graphical interface in anaconda, af.info() is not reported in spyder window but rather in the shell that started it. However, af.get_backend() and af.get_device() are reporting in spyder window.
Example:
import arrayfire as af

af.info()

af.get_backend()
Out[3]: 'unified'

af.get_device()
Out[4]: 0

Thanks for all your work.

@gul916 af.info() prints to stdandard output. It doesn't return a string so it is not visible. You can use af.info_str() which is an equivalent function to print in a notebook or spyder window.

Thank you for your quick reply. af.info_str() works fine. All is on one line, but it is not due to arrayfire. Maybe do you know how to solve it ?

@gul916 Use print(af.info_str()) Do not rely on the repl to print it properly.

Thanks, you were faster than me !


Update ThirdParty.json

No longer includes the transitive dependencies of cesium-native. Also updated the MikkTSpace license to indicate it's Zlib, not something special to MikkTSpace.

Thanks for the pull request @kring!

:heavy_check_mark: Signed CLA found.

Reviewers, don't forget to make sure that:

[ ] Cesium for Unreal Samples works.

Oops realized I opened this PR into ue5-main instead of ue4-main. Maybe ue4-main should be the default? This is such a pain. In any case, I've now cherry picked the contents of this PR into ue4-main as well.


upgrade to smartsense 1.3.0 which is now the default in Ambari 2.4

remove blueprint gateway configurations
disable gateway service, but keep gateway config (hst now has an embedded gateway which uses the file)
ensure hst service is enabled at next boot
minor change to smartsense.account.name

Can one of the admins verify this patch?

Can one of the admins verify this patch?

@biharitomi to review

Added another commit to consolidate the salt work and remove scripts.

LGTM


Python project naming convention

Simple names, why do we need datascience-practice- ... in the name?
Use alphabet casing properly like visualizing-inequalities-in-life-expectancy

I've updated the name for this project, please keep this in mind for future.

CC @Sarvam-Mittal

Okie , Will take care ..


Files Still Not Loaded for Scenarios and Tests

The issue that was logged in #1430 has still not been fixed. Even in v0.80.1.
@mldangelo I added a comment in that issue after the issue was closed.

Hey @mrafnadeem-apimatic,
I’m really sorry that this issue has been a persistent pain. I’ve pushed a fix in PR #331, and it’s now released!
When you have a moment, please give the latest version a spin and let me know if it does the trick. I really appreciate you bringing this up again—your feedback helps make the project better for everyone.
Thanks a ton for your patience and for being part of the community!

Hi @mldangelo, thanks a bunch for putting in the time to fix these issues. Tests and scenarios are both loading fine from external files.
I have just one comment based on my testing: The docs should contain examples of how external scenario or tests' files should be referenced. For example, I assumed it would load if I used scenario.yaml as a reference but actually I had to use `file://scenario.yaml'

Hi @mrafnadeem-apimatic,
Thank you for your patience and for testing the fix. I’m glad to hear that the tests and scenarios are now loading properly from external files!
I’ve also updated the documentation to clarify how external scenario or test files should be referenced—using file://—with this commit: ddcc6e5. Your feedback was incredibly helpful in improving the project.
If you encounter any further issues or have suggestions, please don’t hesitate to reach out again. Thanks for being an active part of the community and helping us improve promptfoo for everyone!


Unit | Component | sl drop button: There are no references to Ember.$, $ or jQuery

not ok 433 PhantomJS 1.9 - Unit | Component | sl drop button: There are no references to Ember.$, $ or jQuery
    ---
        actual: >
            null
        message: >
            Died on test #1     at test (http://localhost:7357/assets/test-support.js:3025)
                at testWrapper (http://localhost:7357/assets/test-support.js:6192)
                at test (http://localhost:7357/assets/test-support.js:6205)
                at http://localhost:7357/assets/tests.js:23438
                at http://localhost:7357/assets/vendor.js:152
                at tryFinally (http://localhost:7357/assets/vendor.js:33)
                at http://localhost:7357/assets/vendor.js:158
                at http://localhost:7357/assets/test-loader.js:60
                at http://localhost:7357/assets/test-loader.js:51
                at http://localhost:7357/assets/test-loader.js:82
                at http://localhost:7357/assets/test-support.js:6024: Attempted to wrap $ which is already wrapped
        Log: |
    ...

Will likely be resolved by https://github.com/softlayer/sl-ember-components/issues/1503

Resolved by https://github.com/softlayer/sl-ember-components/issues/1503


chore: Update gulp from 3.9 to 4.0

Convert tasks which run in parallel

related: #84

I mistook the related issue.
false: #84
true: #87