Word embeddings update

Description
This PR contains a few improvements for the word embeddings training and inference.
Checklist
Essentials

[X] Changes are complete (i.e. I finished coding on this PR)
[X] All changes have test coverage
[X] Code is well-documented

Changes

[X] Support masking of accidental hits in UnigramCandidateSampler (moved to scripts)
[X] TokenEmbedding.__setitem__ now allows setting vectors for new/unknown tokens by default. Can be disabled by setting allow_extend=False.
[X] TokenEmbedding supports unknown_lookup and unknown_autoextend arguments. If unknown token is encountered and unknown_lookup specified, unknown_lookup[tokens] will be called to obtain an embedding for the unknown token. If unknown_autoextend is True, a new index will be assigned to the token and the embedding will be saved in the TokenEmbedding.
[X] Remove EmbeddingModel.to_token_embedding and introduce EmbeddingModel.getitem, making the trainable EmbeddingModels valid arguments for TokenEmbedding unknown_lookup.
[X] Add load_fasttext_format to FasttextEmbeddingModel which supports reading a model.bin file created by facebookresearch/fastText library.
[X] Change ngram hash function to match facebookresearch/fastText implementation compiled with GCC / clang compiled on x86 for non-ASCII (previously matched version compiled on ARM)

Comments

Speed comparision

fasttext C++: ~20k words per second per thread
gluon: ~150k per second with batch size 2048

Merge train_fasttext.py and train_word2vec.py to a single script

It is easier to maintain a single script and put the subword related functionality behind a few if statements. I think it is still easy to understand for users.

Speed-up thanks to now not anymore needed nd.waitall() calls.

https://github.com/apache/incubator-mxnet/pull/11306

Speed-up and memory savings due to re-introducing word-deduplication before  computing subwords

There is a bug in nd.Embedding that caused nan values before. Now a workaround to disable the flaky Operator was merged: https://github.com/apache/incubator-mxnet/issues/11314

Job PR-159/6 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/6/index.html

Job PR-159/9 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/9/index.html

(This failed for a few times due to the pandoc OSError when building doc)

Job PR-159/10 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/10/index.html

Job PR-159/12 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/12/index.html

I suggest to review this and https://github.com/dmlc/gluon-nlp/pull/160 together as the changes are intertwined. I have closed https://github.com/dmlc/gluon-nlp/pull/160 and pushed the commits here.

Please document all the API changes at the top. We should start providing this information in releases.

Job PR-159/13 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/13/index.html

Job PR-159/20 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/20/index.html

Job PR-159/24 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/24/index.html

Job PR-159/25 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/25/index.html

Job PR-159/26 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/26/index.html

Job PR-159/29 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/29/index.html

Job PR-159/34 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/34/index.html

Job PR-159/37 is complete.
Docs are uploaded to http://gluon-nlp-staging.s3-accelerate.dualstack.amazonaws.com/PR-159/37/index.html


Highlight Matching Braces

Does lapce have any support for highlight matching braces,  parens, or square brackets?

At the moment, I don't think we don't have any highlighting for braces (and others)


iOS crash when setting duck

Checklist

[X] I read the troubleshooting guide before raising this issue
[X] I made sure that the issue I am raising doesn't already exist

Current bug behaviour
When the application wants to set ducking, it works on Android but crashes on iOS.
It seems like the category defaultToSpeaker is set by default, and setting the duck option in addition causes the crash.
Expected behaviour
The application doesn't crash on iOS and ducking works.
Steps to reproduce
Run the code included in the snippet.
Code sample

Code sample
import 'dart:async';

import 'package:audioplayers/audioplayers.dart';
import 'package:flutter/material.dart';

Future<void> main() async {
  WidgetsFlutterBinding.ensureInitialized();
  await initPlayer();
  runApp(Container());
}

Future<void> initPlayer() {
  return AudioPlayer.global.setAudioContext(
    AudioContextConfig(duckAudio: true).build(),
  );
}

Affected platforms
iOS
Platform details
iPhone 14, iOS 16.0
iPhone Xs, iOS 16.4.1 (a)
AudioPlayers Version
4.0.1
Build mode
debug, release
Audio Files/URLs/Sources
No need for sound files, the application crashes before that.
Screenshots
No response
Logs

Full Logs

2023-05-06 14:51:54.377566+0200 Runner[717:47684] Metal API Validation Enabled
2023-05-06 14:51:54.534371+0200 Runner[717:47963] flutter: The Dart VM service is listening on http://<IP_ADDRESS>:54130/uL1ofWVhMDI=/
2023-05-06 14:51:54.675303+0200 Runner[717:47684] [as_client]     AVAudioSession_iOS.mm:2194  Error: category option 'defaultToSpeaker' is only applicable with category 'playAndRecord'
2023-05-06 14:51:54.675830+0200 Runner[717:47684] [as_client]     AVAudioSession_iOS.mm:2370  Failed to set category, error: -50
2023-05-06 14:51:54.679279+0200 Runner[717:47945] [VERBOSE-2:dart_vm_initializer.cc(41)] Unhandled Exception: PlatformException(DarwinAudioError, Error configuring global audio session: Error Domain=NSOSStatusErrorDomain Code=-50 "(null)", null, null)
#0      StandardMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:653:7)
#1      MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:315:18)
<asynchronous suspension>
#2      initPlayer (package:time_it/main.dart:13:3)
<asynchronous suspension>
#3      main (package:time_it/main.dart:8:18)
<asynchronous suspension>
Message from debugger: Terminated due to signal 9

Related issues / more information
No response
Working on PR
no way

Ok, the reason is that AudioContextConfig has forceSpeaker as the default, which is pretty surprising, as:

An empty instance (AudioContextConfig()) behaves differently than not setting the context. I don't know, I wouldn't expect this behavior.
It overrides the system settings by default, at least this is my understanding: if my phone has a Bluetooth speaker connected, I expect all sound to go there by default, and this happens all apps that I know.

What is the reasoning behind forceSpeaker being the default?

Could you state a ios context configuration, that you would consider as default?
See: https://pub.dev/documentation/audioplayers_platform_interface/latest/audioplayers_platform_interface/AudioContextIOS-class.html
I expect something like this maybe:
AudioContextIOS(
      category: AVAudioSessionCategory.playAndRecord,
      options: [
          AVAudioSessionOptions.mixWithOthers,
          AVAudioSessionOptions.defaultToSpeaker,
          AVAudioSessionOptions.allowBluetooth,
          AVAudioSessionOptions.allowBluetoothA2DP,
          AVAudioSessionOptions.allowAirPlay,
      ],
    )

The default for me would be the same exact behavior that we get when we don't specify any AudioContext in Dart at all. I don't know what it actually is, but the people who know the code should be able to quickly get the information. Maybe this means the platform default apply?
Currently, the constructors, when called without any parameters, result in different behavior, e.g. for Android they change the audioFocus to something other than null (see https://github.com/bluefireteam/audioplayers/issues/1495), and they are definitely not good on iOS as they cause a crash (due to setting the category to playback, but playAndRecord is needed). This makes it hard or even impossible to change the settings for one platform and keep the default for the other. This is definitely the case when I need to change them for iOS, as this forces me to set one for Android as well, and this in turn makes it impossible to revert to the default behavior (again, see https://github.com/bluefireteam/audioplayers/issues/1495).

The default values for native ios are stated here: https://github.com/bluefireteam/audioplayers/blob/6cd5656c0c5deaab1fb4af78a5b7632402c3a1d3/packages/audioplayers_darwin/ios/Classes/AudioContext.swift#L9
The default values for ios in dart are here: https://github.com/bluefireteam/audioplayers/blob/6cd5656c0c5deaab1fb4af78a5b7632402c3a1d3/packages/audioplayers_platform_interface/lib/src/api/audio_context.dart#L108
So the only difference would be changing AVAudioSessionCategory.playback to playAndRecord.

Hmm the default for ios is playback and not playAndRecord.
https://developer.apple.com/documentation/avfaudio/avaudiosession
We should maybe use playback as the default in the AudioContextIOS?
I also could not reproduce the Error: category option 'defaultToSpeaker' is only applicable with category 'playAndRecord' although it would make sense. Maybe I need a real device so that it is thrown?
I could also imagine that defaultToSpeaker is only needed, because we also use playAndRecord, so we could just leave out both and it would not play from Earpiece, but don't actually know:
https://developer.apple.com/documentation/avfaudio/avaudiosession/categoryoptions/1616462-defaulttospeaker

Yes you need a device. The sample starts just fine on the simulator but crashes on a real device 100% of the time.

We should maybe use playback as the default in the AudioContextIOS?

It currently is the default on in AudioContextIOS, but this doesn't work with the other default of enabling the defaultToSpeaker option, that's the whole issue here. The crash happens and it is documented that it is not allowed: https://developer.apple.com/documentation/avfaudio/avaudiosession/categoryoptions/1616462-defaulttospeaker#discussion (You can set this option only when using the playAndRecord category.)
I'm guessing that's why the native default of audioplayers_ios is playAndRecord. All my PR does is it aligns the Dart default with it.
As for the defaults, AFAIK there are 3 of them:

The platform defaults.
The defaults that the native part of audioplayers uses when no other context is set. This one differs from the iOS defaults (playback vs playAndRecord and forcing speakers) and this must have been your decision at some point in the past.
The Dart defaults, which differ from the iOS part, which is the issue here.

I think it is valid for your package to have other defaults than the platform (i.e. you chose to ignore 1. above), but they should be consistent between iOS and Dart, and this is violated. As far as what you want the defaults to be, you need to decide, your package.
Having playback as the default category, and NOT specifying defaultToSpeaker is exactly what I'm doing, and it's working fine. However, it has its own set of issues if you do this in the library:

It is a breaking change as the defaults your users rely on will change.
This would make it inconsistent with Android, and very surprising to your users, so you probably would need to change the default for Android as well - another breaking change. Not sure about other platforms.
More issues with AudioContextConfig and its buildIOS functions - if someone wants ducking the AudioContextConfig.buildIOS should change the category to playAndRecord, or AudioContextConfig.validateIOS should fail.

As you can see, changing the default is a much more involved task than just making this consistent across iOS and Dart (my PR). But I am all for removing the default of forcing to speaker, I don't understand why you want this, and according to my tests it doesn't even work anyway (or maybe I don't understand what it should do?).


How can we use the Talker with release mode?

Is your feature request related to a problem? Please describe.
When sign the application with release mode. I don't want to print sensitive data in console but want to keep send logs to Firebase Crashlytics via Talker. Now on Talker library has enable property to control it but when we disable then all talker features will be disabled.
Describe the solution you'd like
Do we have any ways to keep the Talker process still running when enable=fasle but do not print logs in console for release mode or keep the TalkerObserver still running even the talker settings is disabled?

Hello @cogivn !
You can set useConsoleLogs field for these purposes
https://github.com/Frezyx/talker/tree/master/packages/talker#-customization
final talker = TalkerFlutter.init(
  settings: TalkerSettings(
    enabled: true,
    useConsoleLogs: kDebugMode,
  ),
  observer: SentryTalkerObserver(),
);


Avoid error when container::mapped_type is defined as void

Found a problem when trying to serialize this container since mapped_type was defined for both the set and map type. May be worth having a static assert to catch when someone else does this and give a more readable error. https://github.com/martinus/unordered_dense/issues/48
Currently this is my solution so that the libraries function together.

Thanks for the PR for some reason it didn’t show in my inbox. I see you got a solution in the linked thread so is there still a need to merge this? I think your reasoning is good for mapped_type only existing in maps and therefore this change is not needed

Well I got an edit through for the linked container, so if there were a need there's less of one now. It's a niche edge case for libraries that might have a similar design, I've no idea how many are out there that might do this. I honestly think having void for a map structure makes sense intuitively to treat as a set. So personally, I'm using this edit.
I mean if I were going to to argue about this edit and the standard together I'd say in theory without this edit someone might try to serialize something like:
std::map<T,void>
std::unordered_map<T, void>

and expect that to work, but currently it won't. I just by chance I guess ran into this problem just with an external library.

I think even with this edit making a std::map to void will not work, what do you think?

Huh, well I didn't exactly test it, looks like you're right.

I’m closing, if this needs to be brought back alive let me know


Undefined Reference to Symbol 'GenerateDiagAndOffd'

Hi Guys,
I am building MFEM 3.4 using CMake on Ubuntu 18.04. Hypre and Metis were built successfully prior to MFEM. When building MFEM, the following error occurred (a portion of the build output is listed below)
~/mfem-3.4/build$ make -j 4
Scanning dependencies of target mfem_miniapps_common
[  0%] Built target copy_data
[  1%] Building CXX object miniapps/common/CMakeFiles/mfem_miniapps_common.dir/mesh_extras.cpp.o
[  1%] Building CXX object miniapps/common/CMakeFiles/mfem_miniapps_common.dir/fem_extras.cpp.o
[  1%] Built target exec_prerequisites
[  2%] Building CXX object miniapps/common/CMakeFiles/mfem_miniapps_common.dir/pfem_extras.cpp.o
[ 38%] Built target mfem
Scanning dependencies of target ex9p
[ 39%] Building CXX object examples/CMakeFiles/ex9p.dir/ex9p.cpp.o
Scanning dependencies of target ex17p
[ 40%] Building CXX object examples/CMakeFiles/ex17p.dir/ex17p.cpp.o
Scanning dependencies of target ex13p
[ 41%] Building CXX object examples/CMakeFiles/ex13p.dir/ex13p.cpp.o
[ 41%] Linking CXX executable ex9p
[ 41%] Linking CXX static library libmfem_miniapps_common.a
[ 41%] Built target mfem_miniapps_common
Scanning dependencies of target ex14p
[ 42%] Building CXX object examples/CMakeFiles/ex14p.dir/ex14p.cpp.o
/usr/bin/x86_64-linux-gnu-ld: ../libmfem.a(hypre.cpp.o): undefined reference to symbol 'GenerateDiagAndOffd'
//usr/lib/x86_64-linux-gnu/libHYPRE_parcsr_mv-2.13.0.so: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
examples/CMakeFiles/ex9p.dir/build.make:102: recipe for target 'examples/ex9p' failed
make[2]: *** [examples/ex9p] Error 1
CMakeFiles/Makefile2:1434: recipe for target 'examples/CMakeFiles/ex9p.dir/all' failed
make[1]: *** [examples/CMakeFiles/ex9p.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
At 42%, the function call to 'GenerateDiagAndOffd' in hypre.cpp was undefined. The 'GenerateDiagAndOffd' function can be found in 'par_csr_matrix.c' as part of hypre_2.11.2.
Any help to fix this problem is highly appreciated.
Thanks,
PCPT

It looks like you installed HYPRE directly from the Ubuntu repositories - they perform an installation that differs from the normal HYPRE build. I think they break the single libHYPRE.a or libHYPRE.so into multiple smaller libraries - e.g. I see libHYPRE_parcsr_mv-2.13.0.so in the output you posted above.
For this reason, you will need to explicitly set the compile and link options for HYPRE by setting the CMake variables HYPRE_INCLUDE_DIRS and HYPRE_LIBRARIES when configuring MFEM. Judging by the above output, you need to make sure /usr/lib/x86_64-linux-gnu/libHYPRE_parcsr_mv-2.13.0.so is listed as part of HYPRE_LIBRARIES.
Alternatively, you can build HYRPE yourself - that is usually straightforward - see http://mfem.org/building/#parallel-mpi-version-of-mfem. After building HYPRE, you can configure MFEM with the CMake option -DHYPRE_DIR=/path/to/hypre where the directory/path/to/hypre should contain the include and lib directories created by the HYPRE build.
Let us know if you have any further questions.

You can also use LD_PRELOAD to solve this problem without compiling libHYPRE from source.
For example, on Ubuntu 20.04, I was getting the error "undefined symbol: HYPRE_ParaSailsSolve" for another app that uses libHYPRE (laghos). After installing libhypre-dev, the necessary .so file is at /usr/lib/x86_64-linux-gnu/libHYPRE_core.so. So, the command becomes
LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libHYPRE_core.so ./laghos. A similar setup should work for mfem.


Why is Encodec only encoding 1 frame?

Hi, thanks for the code! When I'm running naturalspeech2 with Encodec from this repo, I found these codes ensures that number of time frames equals 1 but don't quite understand why it has to be the case. Could you help me understand this?
I checked in https://github.com/lucidrains/audiolm-pytorch/blob/42da76b644eb3e16559382333488fd0fdd719611/audiolm_pytorch/encodec.py#L117 the encoded_frames is always a list of length 1. And this is because when entering the model in Encodec, inside encode function segment_length is always set to the original length of the whole audio. I'm wondering if it's a problem of the initializing in EcodecWrapper? Thanks!
    def encode(self, x: torch.Tensor) -> tp.List[EncodedFrame]:
        """Given a tensor `x`, returns a list of frames containing
        the discrete encoded codes for `x`, along with rescaling factors
        for each segment, when `self.normalize` is True.

        Each frames is a tuple `(codebook, scale)`, with `codebook` of
        shape `[B, K, T]`, with `K` the number of codebooks.
        """
        assert x.dim() == 3
        _, channels, length = x.shape
        assert channels > 0 and channels <= 2
        segment_length = self.segment_length
        if segment_length is None:
            segment_length = length
            stride = length
        else:
            stride = self.segment_stride  # type: ignore
            assert stride is not None

        encoded_frames: tp.List[EncodedFrame] = []
        for offset in range(0, length, stride):
            frame = x[:, :, offset: offset + segment_length]
            encoded_frames.append(self._encode_frame(frame))
        return encoded_frames

Oh I see, the segment is different from the model's frame rate, so even if the length of the list is 1, the code is already in shape of batch * quantizer * time frame


Have you seen the material-components ?

Hi, Yesterday, Google published the material-components in NPM. Now, we just integrate that into Vue to get full usable material components used the correct guidelines : https://github.com/material-components/material-components-web

Yep. I saw it yesterday. But I will continue with the development of Vue Material. Thanks.


Distribute ESM alongside CJS

Issue for tracking ESM support. PRs welcome! @apollo/server distributes both, so that could provide some inspiration for the work necessary to implement this.

Why not just distribute ESM (instead of only CJS, which is what we're doing now). It's been 6 years since ESM support was added to nodejs, the ecosystem has moved on and you're creating more work for yourself. node-fetch dropped CJS entirely quite a while ago.

Unfortunately supporting both (in the Apollo Server project) is a requirement for now. This package does not have to follow that requirement since this is a community project in theory (and in practice once someone other than myself wants to maintain it) but as long as I'm maintaining it my preference would be to ship both. It might be a bit more work, but it's work we've done before, should be able to replicate fairly easily, and we only have to do it once.
Apollo's reality is that we support customers who use CJS, so while plenty of popular packages have made the decision to move on, that's not an option for us yet.

It might be a bit more work, but it's work we've done before, should be able to replicate fairly easily, and we only have to do it once.

It is work that's been done before incorrectly. Right now, today, Apollo Server suffers from the dual package hazard. Instances of a server created from ESM will be similar but unrelated to instances created in CJS. This will lead to subtle bugs where instanceof checks fail mysteriously, or global state is maintained in 2 separate locations.
We can observe this in the CLI:
// incorrect dual exports
> require('@apollo/server').ApolloServer === (await import('@apollo/server')).ApolloServer
false
// correctly implemented dual exports
> require('node:fs').readFile === (await import('node:fs')).readFile
true

To correctly support dual exports is actually pretty annoying with lots of tradeoffs. The incorrect support for dual package exports in @apollo/server is what precipitated my comment here. If support in that package was implemented correctly then I would probably have never noticed that this package is CommonJS. To copy and paste an incorrect implementation only poisons the ecosystem further.

Fair point, I'll be sure to get it addressed in AS first before I duplicate anything that's incorrect and propagate the issue.
https://github.com/apollographql/apollo-server/issues/7625
In the meantime, forking it yourself or creating an ESM-only repo to live in this org are my best options for you.

In the meantime, forking it yourself or creating an ESM-only repo to live in this org are my best options for you.

Yeah definitely. It's a single file so I think we're just going to copy/paste into our repository. Thanks!


pyq installation looks for 32 bit executable in 64 bit architecture

Questions

[x] Which operating system are you using (if Linux, please provide flavour of it, i.e RedHat, CentOS or Ubuntu), is it 32-bit, or 64-bit?
Linux Redhat 64bit

[x] Which version of PyQ are you running? Please provide output of  pyq --versions, if PyQ isn't operational, please provide Python interpreter version and PyQ version python -V; python3 -V; pip list | grep pyq:
python 3.6, pyQ 4.1.4

[x] Which version of kdb+ are you using, is it 32-bit or 64-bit?
      64 bit

[x] If on 64-bit, is your QLIC set? Please provide output env | grep QLIC on linux/macOS, or set|grep QLIC on Windows.
 QLIC=/home/user/pyq3/q/lic/lic_file

[x] Did you use virtual environment to install PyQ? If not, why?

     yes

[x] Where is your QHOME? Please provide output env | grep QHOME on linux/macOS, or set|grep QHOME on Windows.
QHOME=/home/user/pyq3/q

[x] Do you use Conda? If so, what version?
               no

Steps to reproduce the issue
We are trying out pyq and running into installation errors – I am trying to point it to the 64bit commercial version, but it always installs the pyq components for the 32bit and then cannot find the 32bit q executable.

$TARGET =  $VIRTUAL_ENV = /home/user/pyq3
(pyq3) $ pyq
qbinpath = /home/user/pyq3/q/l32/q
qbinpath = /home/user/pyq3/q/l32/q
qbinpath = /home/user/pyq3/q/l32/q
qbinpath = /home/user/q/l32/q
but this works just fine
(pyq3) $ QHOME=$VIRTUAL_ENV/q $VIRTUAL_ENV/q/l64/q
KDB+ 3.5 2018.04.25 Copyright (C) 1993-2018 Kx Systems
l64/ 4()core 32104MB
q)
this is the snippet of code used to create the virtualenv
pip install  --target=/tmp/pyqenvtmp virtualenv
python3 /tmp/pyqenvtmp/virtualenv.py $TARGET
rm -rf /tmp/pyqenvtmp
source $TARGET/bin/activate
mkdir $VIRTUAL_ENV/q
cp -r $KDB_DIR/* $VIRTUAL_ENV/q //$KDB_DIR is where 64bit q is stored
echo "export QHOME=$VIRTUAL_ENV/q" >> $VIRTUAL_ENV/bin/activate
echo "export QLIC=$VIRTUAL_ENV/q/lic/licfile" >> $VIRTUAL_ENV/bin/activate
pip install  pyq
I also tried running get_q_arch( os.environ[‘QHOME’]) from setup.py within the virtual environment and it gives me l64
Expected result
pyq should run with 64bit q
Actual result
pyq looks for 32bit q
Workaround
If you know workaround, please provide it here.

Please read installing into a virtual environment instructions carefully.  You need to install kdb+ in $VIRTUAL_ENV/q and your QHOME should be either unset or set to $VIRTUAL_ENV/q.
If it still does not work, please run pip install in verbose mode
pip install -vvv  pyq

and post the results.

I installed again - $QHOME is in $VIRTUAL_ENV/q
Yes - q is in $VIRTUAL_ENV/q
(pyq4) $ echo $QHOME
/home/user/pyq4/q
(pyq4) $ echo $VIRTUAL_ENV
/home/user/pyq
Output of pip install -i $INTERNAL_PYPI_URL --trusted_host $INTERNAL_PYPI_HOST  -vvv pyq
Collecting pyqââââââââââââ
1 location(s) to search for versions of pyq:

http://pypi.site.corp.com/simple/pyq/
Getting page http://pypi.site.corp.com/simple/pyq/
Starting new HTTP connection (1): pypi.site.corp.com
http://pypi.site.corp.com:80 "GET /simple/pyq/ HTTP/1.1" 200 3926
Analyzing links from page http://pypi.site.corp.com/simple/pyq/
Found link http://pypi.site.corp.com/packages/66/2c/d1e1891e293edd7905ac4d1d6e4f9f30ff7e40cebf8e2a2629bf4f9f4152/pyq-4.1.0.post1.tar.gz#sha256=e7552e092ef68196a431aec6a7c2d235b78a4d2ae54e8d3246                                                                         f485fd963e1637 (from http://pypi.site.corp.com/simple/pyq/), version: 4.1.0.post1
Found link http://pypi.site.corp.com/packages/c0/a6/6dad579c65ded93d9da0fdf9e0da268870c9cea5abd6e2d0606b67f0905d/pyq-4.1.1.tar.gz#sha256=72b337007f1f43743bd0f02f05f16331ddbad46a7fd00bfced158f41                                                                         d2bfee18 (from http://pypi.site.corp.com/simple/pyq/), version: 4.1.1
Skipping link http://pypi.site.corp.com/packages/4f/bd/e7026ae10439d36eca775d2075ef2a121d9c252e8408d5eaa09189c47fd3/pyq-4.1.2b1-cp27-cp27m-macosx_10_12_intel.whl#sha256=6138d0fc73d1a91f7bb53c2c                                                                         5d2eff2f7c0951b66262fec9847ee20aa614009a (from http://pypi.site.corp.com/simple/pyq/); it is not compatible with this Python
Skipping link http://pypi.site.corp.com/packages/13/a3/a98edf0c3f021ebf404c00287a93cc9a31a9eb32e0273727ffae94788379/pyq-4.1.2b1-cp27-cp27m-win32.whl#sha256=c1e9849a3b0b803f59229f65690bab69050ab                                                                         e2a81cd7ca096a73ea82a3b3fe4 (from http://pypi.site.corp.com/simple/pyq/); it is not compatible with this Python
Skipping link http://pypi.site.corp.com/packages/94/3b/3ffc69412108b64846e176bbee5196d6161436ce40daf4e6bb58d589b20e/pyq-4.1.2b1-cp27-cp27m-win_amd64.whl#sha256=233f8ee5648eab7d69772e63cd7080174                                                                         9deb0498b5a847df8437155347aaa33 (from http://pypi.site.corp.com/simple/pyq/); it is not compatible with this Python
Skipping link http://pypi.site.corp.com/packages/24/55/08decbc9fa08e6d4a051aba7812b4a5d3182d0fdbf10e1b87af11d1c4de8/pyq-4.1.2b1-cp36-cp36m-macosx_10_12_intel.whl#sha256=b007611b5c30b9cff0036e85                                                                         d1d018286cfcbed1fcc08f72114f7631942609bf (from http://pypi.site.corp.com/simple/pyq/); it is not compatible with this Python
Skipping link http://pypi.site.corp.com/packages/02/ab/96a7d742d5279a23654201a16d34cda0019fbaaef4fa64984da13ce06f04/pyq-4.1.2b1-cp36-cp36m-win32.whl#sha256=59f27fa5d4a034ecb0fd2a4c97558aa411cd2                                                                         012d8143c4cfcd2dd1395e5f33a (from http://pypi.site.corp.com/simple/pyq/); it is not compatible with this Python
Skipping link http://pypi.site.corp.com/packages/53/fb/9cadc05b6cb919ee345c266e76c19257b33c1e9546bd9d22792f4c1e2b49/pyq-4.1.2b1-cp36-cp36m-win_amd64.whl#sha256=0fb33044482ae7b71750949a9a46562e5                                                                         d262099eb68caef1bc474e7688abd23 (from http://pypi.site.corp.com/simple/pyq/); it is not compatible with this Python
Skipping link http://pypi.site.corp.com/packages/29/ba/9c7184f72fd9328f949e770402dc98f8c34d46fe24c5075ce8d57a1acb93/pyq-4.1.2-cp27-cp27m-win32.whl#sha256=50fc98f48795b6ac7e05fc35bcfc415e5170d32                                                                         18c8f4d4e02362a601f8fa9c0 (from http://pypi.site.corp.com/simple/pyq/); it is not compatible with this Python
Skipping link http://pypi.site.corp.com/packages/48/90/76ea75b94cd15b31db1c304fe0d83a07b82a788295f57e5981cbcdcd377f/pyq-4.1.2-cp27-cp27m-win_amd64.whl#sha256=45b89c77ac6ef96fd3c18964fbf3c1aad9a                                                                         6fa8c65cfb1dc52dd33552ac900a7 (from http://pypi.site.corp.com/simple/pyq/); it is not compatible with this Python
Skipping link http://pypi.site.corp.com/packages/fb/4f/bbbe1d029875e3492afce4b4b44717c88228420be53a9ce14a8920280f66/pyq-4.1.2-cp36-cp36m-win32.whl#sha256=05c51e3d538e89b36583d2c13bc53443dc97e2f                                                                         c60ea52dca82e67aa9c54d570 (from http://pypi.site.corp.com/simple/pyq/); it is not compatible with this Python
Skipping link http://pypi.site.corp.com/packages/dd/19/e7e4e4540061ec2946fc6941b78dd16576d5c1802ed155cfede3bf004278/pyq-4.1.2-cp36-cp36m-win_amd64.whl#sha256=8cb1cd6378dd32bf852cbd47fda4f73624d                                                                         89aa683f5b880e1179320f2a1fae1 (from http://pypi.site.corp.com/simple/pyq/); it is not compatible with this Python
Found link http://pypi.site.corp.com/packages/99/04/a8c7f814ae137e3fdb21f43666221557f76ca7f59fa3c992800c2d159502/pyq-4.1.2.tar.gz#sha256=09ce6ae8a4b2a2c36008782108504b357c52c4d3cc1db602b965790b                                                                         4ece865b (from http://pypi.site.corp.com/simple/pyq/), version: 4.1.2
Found link http://pypi.site.corp.com/packages/49/bf/81a4f658f7b89f1b75903b9470240d8c20746efd5c2c3b439cc214e28990/pyq-4.1.3.tar.gz#sha256=e4e95970a930408d64b7351ad80c4c601f1ba414379de4d03717138d                                                                         13a2a02f (from http://pypi.site.corp.com/simple/pyq/), version: 4.1.3
Found link http://pypi.site.corp.com/packages/53/de/195ce13d50784489365fee87d1e7d637fa2e42f3c5ae359d56c13595c93c/pyq-4.1.4.tar.gz#sha256=3386268669be9f6c3826862edfd8fc91e7b1be2ff246ebc2275c30ae                                                                         a5075211 (from http://pypi.site.corp.com/simple/pyq/), version: 4.1.4
Using version 4.1.4 (newest of versions: 4.1.0.post1, 4.1.1, 4.1.2, 4.1.3, 4.1.4)
Using cached wheel link: file:///home/user/.cache/pip/wheels/3c/fa/a6/2ffdf068045e1c3f6785ae31d16973f687617c0730795f2cb8/pyq-4.1.4-cp36-cp36m-linux_x86_64.whl
Installing collected packages: pyq

Successfully installed pyq-4.1.4

Did you resolve your issue?

No , the same issue still exists. It installed successfully, but fails looking for 32bit q instead of 64bit.

You really have to tell us more than that.  What command do you run?  What output do you expect and what output do you get?  One problem I can see in your log is this:
Using cached wheel link: file:///home/user/.cache/pip/wheels/.../pyq-4.1.4-cp36-cp36m-linux_x86_64.whl

You have a .whl file left from a command that you don't show us.
Also, we have no way to know what  $INTERNAL_PYPI_URL or $INTERNAL_PYPI_HOST variables are.
If you prefer following someone else's instructions instead of those at code.kx.com, you should ask those who instructed you for help.

Sorry, I thought I gave you all this information in the first comment - the exact commands I run are below.   I have tried to stay pretty close to what is at code.kx.com. The main differences are ,
a) public pypi is blocked, so we install from a pypi within the corporate network
b) there is already a directory with the kdb installation and we copy q from there into the virtual env.
$INTERNAL_PYPI_HOST and $INTERNAL_PYPI_URL are just pointers to the internal pypi installation which is just a copy of public pypi.
What I expect:
When I run pyq - it starts up pointing to l64/q
What actually happens:
I cannot start pyq, it looks for l32/q which is not there and fails
$ source /home/user/pyq4/bin/activate
(pyq4) $ pyq
qbinpath = /home/user/pyq4/q/l32/q
qbinpath = /home/user/pyq4/q/l32/q
qbinpath = /home/user/pyq4/q/l32/q
qbinpath = /home/user/q/l32/q
Exact commands I run
pip install  -i $INTERNAL_PYPI_URL --trusted_host $INTERNAL_PYPI_HOST -target=/tmp/pyqenvtmp virtualenv
python3 /tmp/pyqenvtmp/virtualenv.py $/home/user/pyq4
rm -rf /tmp/pyqenvtmp
source $/home/user/pyq4/bin/activate
mkdir $VIRTUAL_ENV/q
cp -r $KDB_DIR/* $VIRTUAL_ENV/q //$KDB_DIR is where 64bit q is stored
echo "export QHOME=$VIRTUAL_ENV/q" >> $VIRTUAL_ENV/bin/activate
echo "export QLIC=$VIRTUAL_ENV/q/lic/licfile" >> $VIRTUAL_ENV/bin/activate
pip install -i $INTERNAL_PYPI_URL --trusted_host $INTERNAL_PYPI_HOST pyq

OK, we are getting somewhere, but you still did not provide a clean build log.  Please run
pip install -vvv --no-binary pyq pyq

You don't have to post the entire story of finding the sources on pypi.  Try to find the relevant lines.
You should be looking for a line with -DQARCH in it.  If it shows l32 it means you are building pyq with a 32-bit python.  Check what your pip command uses:
head -1 $(which pip)

I was just able to fix this by running pip with --no-cache-dir. Thank you for the pointer about the cached wheel file. I think a previous attempt at installation had left some files around which was being picked up by this.
Thanks a lot for your help!


cannot install - utils package missing

Where can I find the utils package referenced in your package?
I could not install / find a working version on GitHub or for pip.

it is work ，Modify stacking.py file as follow：
#import util
from stacked_generalization.lib.util import *
find " util. " and remove it


[SILENT FAILURE] Import-Module MyModule -Verbose writes nothing, does nothing

Here is YET ANOTHER silent failure!
PS C:\source> Find-Module -Name MyCompany.PowerShell.SqlClone

Version              Name                                Repository           Description
-------              ----                                ----------           -----------
1.0.0                MyCompany.PowerShell.SqlClone           MyCompany-PowerShell     MyCompany.PowerShell.SqlClone
1.0.0                MyCompany.PowerShell.SqlClone           MyCompany-Development    MyCompany.PowerShell.SqlClone

PS C:\source> Find-Module -Name MyCompany.PowerShell.SqlClone | % { Get-Command -Module "$_" }
PS C:\source>

returns no output
PS C:\source> Import-Module MyCompany.PowerShell.SqlClone -Verbose
PS C:\source>

returns no output
I have NO IDEA why this is not working.  It was literally working last week.  But it sure doesn't help that -Verbose does NOTHING.
Check this out:
PS C:\source> Find-Module -Name MyCompany.PowerShell.SqlClone | % { Get-Command -Module "$_" -Verbose }
PS C:\source> install-module -Name MyCompany.PowerShell.SqlClone -Repository MyCompany-Development

Untrusted repository
You are installing the modules from an untrusted repository. If you trust this repository, change its InstallationPolicy value by running the Set-PSRepository cmdlet. Are you sure you want to install the modules from 'MyCompany-Development'?
[Y] Yes  [A] Yes to All  [N] No  [L] No to All  [S] Suspend  [?] Help (default is "N"): a
WARNING: Version '1.0' of module 'MyCompany.PowerShell.SqlClone' is already installed at 'C:\Program Files\WindowsPowerShell\Modules\MyCompany.PowerShell.SqlClone\1.0'. To install version '1.0.0', run Install-Module and add the -Force parameter, this command will install
version '1.0.0' side-by-side with version '1.0'.

Here is even more 👍
PS C:\source> install-module -Name Weiss.PowerShell.SqlClone -Repository Weiss-Development -Force
PS C:\source> Find-Module -Name Weiss.PowerShell.SqlClone | % { Get-Command -Module "$_" -Verbose }
PS C:\source> import-module Weiss.PowerShell.SqlClone
PS C:\source> get-command *clone*

CommandType     Name                                               Version    Source
-----------     ----                                               -------    ------
Function        New-VirtualDiskClone                               <IP_ADDRESS>    Storage
Cmdlet          Connect-SqlClone                                   <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Export-DfsrClone                                   <IP_ADDRESS>    DFSR
Cmdlet          Get-DfsrCloneState                                 <IP_ADDRESS>    DFSR
Cmdlet          Get-SqlClone                                       <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Get-SqlCloneBackupLocation                         <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Get-SqlCloneImage                                  <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Get-SqlCloneImageLocation                          <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Get-SqlCloneMachine                                <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Get-SqlCloneSqlServerInstance                      <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Get-SqlCloneTemplate                               <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Import-DfsrClone                                   <IP_ADDRESS>    DFSR
Cmdlet          New-ADDCCloneConfigFile                            <IP_ADDRESS>    ActiveDirectory
Cmdlet          New-SqlClone                                       <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          New-SqlCloneImage                                  <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          New-SqlCloneMask                                   <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          New-SqlCloneSqlScript                              <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          New-SqlCloneTemplate                               <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Remove-SqlClone                                    <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Remove-SqlCloneImage                               <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Remove-SqlCloneMachine                             <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Remove-SqlCloneTemplate                            <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Rename-SqlCloneImage                               <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Reset-DfsrCloneState                               <IP_ADDRESS>    DFSR
Cmdlet          Reset-SqlClone                                     <IP_ADDRESS>6  RedGate.SqlClone.Powershell
Cmdlet          Wait-SqlCloneOperation                             <IP_ADDRESS>6  RedGate.SqlClone.Powershell

John, sorry you've been having so much trouble.
Without access to your module or repository setup, I can't be 100% confident about the issue, but I hope this helps a bit.
Taking this one item at a time.

 Find-Module -Name MyCompany.PowerShell.SqlClone | % { Get-Command -Module "$_" }

Find-Module is part of PowerShellGet. It searches your registerered repositories and returns info on what's available to install.
Get-Command is part of PowerShell, rather than PowerShellGet. Get-Command -Module foo searches the modules already installed on the machine, and returns the commands in that module. So Get-Command -Module MyCompany.PowerShell.SqlClone will return the commands in that module if it is installed, but not the commands from a module which is in a repository but not installed yet.
Get-Command -Module xyz , where xyz is not installed on the system, returns no output rather than raising an error. (Same for Get-Module xyz.) You could quite reasonably claim that is a bug, but I doubt it can be changed because it would break backward compatibility. If you would like to file a bug on that, it should go in the PowerShell repo rather than PowerShellGet.
Finally, $_ is the whole object, and "$_" gives the .ToString() of that object. The string representation of the module name is not the module's name, but contains more data, eg:
PS C:\Users\edwin> Find-Module -Name AzureRM.Profile | % {"$_"}
@{Name=AzureRM.profile; Version=5.5.1; Type=Module; ...}

So this command doesn't produce any output because it tries to find the commands in a module called "@{Name=MyCompany.PowerShell,SqlClone..." which is not present on your computer.
To find the set of cmdlets in a module in a repository without installing it, run
(Find-Module -Name AzureRM.Profile).AdditionalMetadata.Cmdlets

Import-Module MyCompany.PowerShell.SqlClone -Verbose

Import-Module is part of PowerShell, not PowerShellGet. It loads a module already installed on your computer into the running Powershell instance. In general -Verbose should list the cmdlets and functions exported by the module. You could see this succeed silently if you have a module with no exports. Try running Get-Module MyCompany.PowerShell.SqlClone after this - if you see it in the output, it was loaded.
In general, attempting to import a module which is not installed or is invalid will produce an error. It's possible there is a case where this does not happen, and I would consider that a bug, but we'd need more info to isolate it if so. If you could share a cut-down version of the module which illustrates the problem that would help.

I think this is explained by (1) above.

The main question here is why no Clone commands from the SqlClone library are shown. I think the most likely explanation is that they are not being exported from the module. Try running

Import-Module MyCompany.PowerShell.SqlClone
Get-Module MyCompany.PowerShell.SqlClone
Get-Module MyCompany.PowerShell.SqlClone | select -exp ExportedCommands

If module is loaded but the command list is empty, you need to look at the manifest to see why nothing is exported. If the module is not loaded and there is no error printed, I think there is a bug in Import-Module which we should look into.

Some additional thoughts which may help you in the investigation:

Run Test-ModuleManifest with the module manifest path to verify the exported commands

Test-ModuleManifest -Path 'C:\Program Files\WindowsPowerShell\Modules\MyCompany.PowerShell.SqlClone\1.0\MyCompany.PowerShell.SqlClone.psd1' -Verbose

Review the dot sourcing logic in MyCompany.PowerShell.SqlClone.psm1 for exporting the functions in individual script files.

Verify the values of RootModule, NestedModules and FunctionsToExport entries in the MyCompany.PowerShell.SqlClone.psd1

Try importing the .psm1 file using below command

Import-Module
'C:\Program Files\WindowsPowerShell\Modules\MyCompany.PowerShell.SqlClone\1.0\MyCompany.PowerShell.SqlClone.psm1' -Verbose

Here is something interesting.  From the previous shell I had open (where I suspected it had some "side effect" in my session):
PS C:\WINDOWS\system32>  $result = Test-ModuleManifest C:\source\Infrastructure\SqlClone\Powershell\MyCompany.PowerShell.SqlClone\MyCompany.PowerShell.SqlClone.psd1 -Verbose
VERBOSE: Loading module from path 'C:\source\Infrastructure\SqlClone\Powershell\MyCompany.PowerShell.SqlClone\MyCompany.PowerShell.SqlClone.psm1'.
PS C:\WINDOWS\system32> $result

ModuleType Version    Name                                ExportedCommands
---------- -------    ----                                ----------------
Script     1.0        MyCompany.PowerShell.SqlClone           {Update-Library, Get-SvnDirectory}

PS C:\WINDOWS\system32> Uninstall-Module MyCompany.PowerShell.SqlClone -Verbose
VERBOSE: Performing the operation "Uninstall-Module" on target "Version '1.0' of module 'MyCompany.PowerShell.SqlClone'".
VERBOSE: Successfully uninstalled the module 'MyCompany.PowerShell.SqlClone' from module base 'C:\Program Files\WindowsPowerShell\Modules\MyCompany.PowerShell.SqlClone\1.0'.
PS C:\WINDOWS\system32>  $result = Test-ModuleManifest C:\source\Infrastructure\SqlClone\Powershell\MyCompany.PowerShell.SqlClone\MyCompany.PowerShell.SqlClone.psd1 -Verbose
WARNING: The module manifest member 'ModuleToProcess' has been deprecated. Use the 'RootModule' member instead.
VERBOSE: Loading module from path 'C:\source\Infrastructure\SqlClone\Powershell\MyCompany.PowerShell.SqlClone\MyCompany.PowerShell.SqlClone.psm1'.
PS C:\WINDOWS\system32>  $result = Test-ModuleManifest C:\source\Infrastructure\SqlClone\Powershell\MyCompany.PowerShell.SqlClone\MyCompany.PowerShell.SqlClone.psd1 -Verbose
VERBOSE: Loading module from path 'C:\source\Infrastructure\SqlClone\Powershell\MyCompany.PowerShell.SqlClone\MyCompany.PowerShell.SqlClone.psm1'.
PS C:\WINDOWS\system32> $result

ModuleType Version    Name                                ExportedCommands
---------- -------    ----                                ----------------
Script     1.0        MyCompany.PowerShell.SqlClone           {Update-Library, Update-MyClone, Get-SvnDirectory}

PowerShell and PowerShellGet are obviously closely related. I'm pointing out the difference because they have separate GitHub projects and issues databases. Since Test-ModuleManifest is in PowerShell, other bug reports concerning it are there ( https://github.com/PowerShell/PowerShell/issues?utf8=✓&q=is:issue+is:open+test-modulemanifest) and filing an issue there is the best way to get a resolution. I'd be happy to port a clear bug over, but I'm not sure I can effectively summarize this one.
If you can narrow down the repro to something like "Here's test.psd1; when I run Test-ModuleManifest on it twice, I only get warnings the first time" it'll be a lot easier to isolate the issue and fix it. I have tried running Test-ModuleManifest on the same file several times, and running it on a manifest while another version of the same module is installed, but have not been able to reproduce either problem.

I believe the issue is related to the poor design of Test-ModuleManifest
depending on ModuleCmdletsBase.cs
I recommend the Powershellget team write their own manifest tester and RIP
out all references to PowerShell core, as PowerShellGet is internally using
bad and unreliable code. The link you provided shows how bad
Test-ModuleManifest is: as a Library author, I would not take dependency on
a poorly written function/class.
On Sat, Sep 8, 2018, 1:35 AM Edwin Young<EMAIL_ADDRESS>wrote:

PowerShell and PowerShellGet are obviously closely related. I'm pointing
out the difference because they have separate GitHub projects and issues
databases. Since Test-ModuleManifest is in PowerShell, other bug reports
concerning it are there (
https://github.com/PowerShell/PowerShell/issues?utf8=✓&q=is:issue+is:open+test-modulemanifest)
and filing an issue there is the best way to get a resolution. I'd be happy
to port a clear bug over, but I'm not sure I can effectively summarize this
one.
If you can narrow down the repro to something like "Here's test.psd1; when
I run Test-ModuleManifest on it twice, I only get warnings the first time"
it'll be a lot easier to isolate the issue and fix it. I have tried running
Test-ModuleManifest on the same file several times, and running it on a
manifest while another version of the same module is installed, but have
not been able to reproduce either problem.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/PowerShell/PowerShellGet/issues/321#issuecomment-419614919,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAbT_WOIG9m6Ocq9bprJ7EwOmCyJM7LYks5uY1c4gaJpZM4Wd_-_
.

While I understand your point of view, I am reluctant to write another separate module tester, because both would need to be maintained in future and the buggy implementation would still exist in PowerShell itself. At this point I am going to close this issue because the linked bug tracks the Test-ModuleManifest problem, and this bug doesn't track an actionable issue to fix in PowerShellGet itself. Let me know if you disagree.


[bug] erroneous timeout

What happened?:
panic.go:838] "HTTP" verb="GET" URI="/apis/custom.metrics.k8s.io/v1beta1" latency="25.789098ms" userAgent="Go-http-client/2.0" audit-ID="bb032cb7-e6bd-4aee-8d52-3c8ac71d3987" srcIP="<IP_ADDRESS>:44714" resp=200
wrap.go:53] timeout or abort while handling: method=GET URI="/apis/custom.metrics.k8s.io/v1beta1" audit-ID="bb032cb7-e6bd-4aee-8d52-3c8ac71d3987"

What did you expect to happen?:
No log spam about a request that reports a successful response (200).
Anything else we need to know?:

This is still happening in v0.11.2.
This problem has been going on for nearly 3 years and has gone unaddressed.
As noted above, and not highlighted in previous issues, it would appear that the request was successful, so why the timeout?
Previous issues also claimed that the server was overloaded with the default rules from this chart. However after deleting all the default rules, the issue persists.
Previous issues also claimed that the pods default to too small of a resource constraint, which I've also ruled out by removing all resource constraints and placing on an over powered node.

Environment:

prometheus-adapter version: v0.11.2
prometheus version: v2.38.0
Kubernetes version (use kubectl version): v1.26.10+k3s2

I've been able to track down only one clear issue - the listed srcIP isn't assigned, and I've been able to reproduce this on clusters that have a static workload. Is it possible that the adapter is holding on to some cached IP list somewhere?

/triage accepted
/assign

Which verbose level are you using?

I'll do my best to revisit this, but unfortunately I had to move on to other things and don't know when I'll have capacity to bring up a test cluster again. I'm frankly running out of resources.


[ModelGen] JObject being serialized

Here's a couple of examples where the JObject is being serialized:
{
  "Id": "KF9VucDr3kin1Y5PMV1aXQ",
  "FirstName": "Marcus",
  "LastName": "Bowyer",
  "Phone": "+1-2047894561",
  "Email"<EMAIL_ADDRESS>  "Emails": [
    {
      "__JObject": {},
      "Address"<EMAIL_ADDRESS>    }
  ],
  "__T": "u",
  "LastActive": "2019-08-23T18:02:56.1626927Z"
}

{
  "__T": "p2s",
  "__JObject": {},
  "Id": "98112",
  "ServiceAreas": [
    "SSA0",
    "SSA2",
    "SSA1"
  ]
}

For now, the plan is to strip out all of these properties before persisting data to the database.
I'm also going to rename: __JObject --> __O

I just noticed something important: The root object's __O property will be null after serializing it.  The problem is that the generated ToJObject() methods actually returns the __O property of the data object being converted which will never have an __O property itself since it is the __O property.

I believe the secondary issue in #698 where the conditional was inverted was causing the root __O property to never be initialized because the round trip serializer wasn't being used.

I re-thought the implementation for this over the weekend.  I believe the better approach is to never serialize the __O properties separately and implement custom serialization that walks the object hierarchy calling __Save() on IRoundtripData objects and then persisting the properties from __O instead of letting JSON.NET serialize the real properties.  We'd also have to implement custom parsing.
I believe I can do all of this with limited additional processing and object allocation overhead.

I added a [JsonIgonore] to the generated __O properties so these will no longer be serialized
Remaining work: We need to re-code serialization to make round tripping work.

I'm also temporarily disabling some round trip code generation and will come back to this later: #704


consider using setup_cache

I see us using our hand-written helpers to cache the generated dir in add.py. Seems like there is a better solution

The setup method is run multiple times, for each benchmark and for each repeat. If the setup is especially expensive, the setup_cache method may be used instead, which only performs the setup calculation once and then caches the result to disk. It is run only once also for repeated benchmarks and profiling, unlike setup.

I am afraid that setup_cache might not be useful for us.

which only performs the setup calculation once and then caches the result to disk

What asv can do is to cache in-memory objects and write them to cache.pickle file under temporary benchmark dir. When setup_cache is defined, asv tries to load pickled object. I believe that this approach does not make too much sense for us, since we depend on the repository and its state.

@pared Makes sense.

Closing for now


Tab overflow button needs an accessible name

Describe the bug
Tabs overflow button just says 'button' when using a screen reader, and does not indicate what it does.
How to reproduce

Using a screen reader go https://v1.clarity.design/tabs
Read the overflow dropdown toggle button
You will only hear the word "button"

Versions
App

Angular: [e.g. 6]
Node: [e.g. 8.10.0]
Clarity: [e.g. 0.12.5]

Device:

Type: [e.g. MacBook]
OS: [e.g. iOS]
Browser [e.g. chrome, safari]
Version [e.g. 22]

Additional notes
Add any other notes about the problem here.

Will probably fix it as side effect of another issue. Assigning to myself.

@Jinnie Did we tackle this one yet as part of the overflow work?

Yes. For a blind user this button does not exist now, we're automatically forwarding to the next meaningful button.
Thanks!


Bt bloom

What does this PR do?
What the title says :)
In order to make the tests with key-value cache work, the input format had to be changed in order to be compatible with the Bloom cache format. Perhaps this could be automated by adding to Transformers directly (for the generate method this is done in https://github.com/huggingface/transformers/pull/20213)
Fixes #1175
Duplicate PR of #1187 but I messed up a bit with rebasing there, so I closed that one ;)
Before submitting

[x] Did you make sure to update the documentation with your changes?
[x] Did you write any new necessary tests?

can i ask when we can get this PR merged to optimize bloom? pytorch just added attention bias memory efficient optimization. https://github.com/pytorch/pytorch/pull/104310

@fxmarty ?

Thank you, I'll make sure it is merged this week!


Fix JDK8 Javadoc errors when preparing releases

When I was running mvn release:prepare I was getting errors because Java 8 is much stricter about self-closing HTML tags in Javadoc comments.
I followed this advice which should fix it.

Coverage remained the same at 81.747% when pulling 44acd27c39f7c666b330139e68dc70ea69fb8756 on jstanier:fix-jdk8-javadoc-errors into ce43008aaf5b61ea61f80b22703281842f43a594 on BrandwatchLtd:master.

👍


Simplify unprintable handling in UnpackDomainName

Simplify unprintable handling in UnpackDomainName.
These benchmarks were taking after #844 and show a modest improvement:
name                                   old time/op    new time/op    delta
UnpackDomainName-12                       122ns ± 4%     125ns ± 4%    ~     (p=0.052 n=10+10)
UnpackDomainNameUnprintable-12            149ns ± 1%     138ns ± 4%  -7.51%  (p=0.000 n=10+10)
UnpackDomainNameLongest-12                552ns ± 2%     550ns ± 5%    ~     (p=0.403 n=10+10)
UnpackDomainNameLongestUnprintable-12    2.96µs ± 1%    2.70µs ± 1%  -8.74%  (p=0.000 n=10+10)

name                                   old alloc/op   new alloc/op   delta
UnpackDomainName-12                       64.0B ± 0%     64.0B ± 0%    ~     (all equal)
UnpackDomainNameUnprintable-12            48.0B ± 0%     48.0B ± 0%    ~     (all equal)
UnpackDomainNameLongest-12                 256B ± 0%      256B ± 0%    ~     (all equal)
UnpackDomainNameLongestUnprintable-12    1.02kB ± 0%    1.02kB ± 0%    ~     (all equal)

name                                   old allocs/op  new allocs/op  delta
UnpackDomainName-12                        1.00 ± 0%      1.00 ± 0%    ~     (all equal)
UnpackDomainNameUnprintable-12             1.00 ± 0%      1.00 ± 0%    ~     (all equal)
UnpackDomainNameLongest-12                 1.00 ± 0%      1.00 ± 0%    ~     (all equal)
UnpackDomainNameLongestUnprintable-12      1.00 ± 0%      1.00 ± 0%    ~     (all equal)

Codecov Report

Merging #845 into master will decrease coverage by 0.01%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master     #845      +/-   ##
==========================================
- Coverage   57.69%   57.67%   -0.02%
==========================================
  Files          43       43
  Lines       10856    10854       -2
==========================================
- Hits         6263     6260       -3
- Misses       3504     3505       +1
  Partials     1089     1089

Impacted Files
Coverage Δ

msg.go
79.35% <100%> (-0.07%)
:arrow_down:

server.go
65.96% <0%> (-0.24%)
:arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update fa58975...63f33da. Read the comment docs.


Adds value(forParameter name: String) -> String? as an extension of URL

Codecov Report

Merging #43 into master will decrease coverage by 0.4%.
The diff coverage is 41.66%.

@@            Coverage Diff             @@
##           master      #43      +/-   ##
==========================================
- Coverage   90.98%   90.58%   -0.41%
==========================================
  Files          19        5      -14
  Lines         355      223     -132
==========================================
- Hits          323      202     -121
+ Misses         32       21      -11

Impacted Files
Coverage Δ

CodemineTests/URLParameterTests.swift
41.66% <41.66%> (ø)

Codemine/Extensions/CGPoint+Utilities.swift

Codemine/Extensions/UIView+Utilities.swift

Codemine/Operators.swift

Codemine/Extensions/String+EmailValidation.swift

Codemine/Extensions/DispatchTime+Utilities.swift

Codemine/Application.swift

Codemine/Then.swift

Codemine/Extensions/String+Range.swift

Codemine/Extensions/String+CaseConverter.swift

... and 6 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 313da46...79d0543. Read the comment docs.


how to use app.html template url instead of multi-line template string?

(probably a question instead of an issue)
When I move the multi-line template string in app.ts to a file (app.html, next to app.ts) and specify templateUrl: './app.html', I get an error: Failed to load app.html (main.ts:35).
What do I need to do to use a template file instead of multi-line string in app.ts?

try template: require('./app.html') instead of templateUrl: './app.html';

one way as @samvloeberghs said
or use copy webpack loader

@samvloeberghs - that works for me, but I'm using html-loader?minimise=true to load HTML files in webpack.config.js, instead of raw-loader. This strips the HTML of unnecessary characters (good!) but then Angular2's TemplateNormalizer thinks my HTML is invalid (which is incorrect).
HTML:
 Link

Is that why you are using raw-loader, because of Angular2's buggy HTML parser?

No, I'm not yet at the stage where I want to minify my HTML.
Will definitely look into that in the near future, so if you find a good solution please post your findings here? :+1:

@uglow did you try other configurations? Like for example not to strip single and/or double quotes? As far as I can tell that might be one of the most obvious reasons it's not working, but indeed it should not be as it is valid HTML5.
Angular2 might have other requirements than the way a browser handles HTML5.
@gdi2290 what do you think? :)

@samvloeberghs - The following strings work:

 Link

 Link

These strings do not work:

 Link

 Link

So it appears that the template parser may be looking for "> to determine the end of the start-tag of a HTML element. Notice that  works, even though there are no quotes for the class attribute.
I've raised this question on the Angular repo, and they suggested I raise a new issue. So I'll do that now.

Raised issue 7225 on Angular2

I've documented a Webpack html-loader configuration that seems to work with Angular2.0.0-beta6


Instructions fix for The Farm

This PR contains the following minor changes:

Renamed weightFodder to FodderAmount when referencing the method that provides the fodder amount
Renamed instances of function with method when referencing the FodderAmount method
Included the keyword struct when referring to the weightFodder instance
Updated the names of WeightFodder instances to maintain consistency between comments and function arguments (e.g. replaced twentyFodderNoError says there are -5.0 fodder with negativeFiveFodder says there are -5.0 fodder)

This PR contains the following major change:
The sequence of instructions do not reflect the sequence of cases that need to be handled by the DivideFood function. For example, if the amount of fodder is negative then the error returned by FodderAmount method (e.g. ErrScaleMalfunction or nil) is inconsequential since in this case DivideFood should always return Negative fodder error [Inferred from test cases]. From observation, it appears that negative fodder, no cows and negative cows take precedence over ErrScaleMalfunction and other errors which in turn take precedence over the happy-path case. The instructions have been rearranged (and modified a bit) to reflect this sequence.

@RajivTS Thanks for raising all these points. I agree with most of the minor fixes. I left a suggestion for improving the sentence in task 1 above.
I don't think changing the order of the tasks is a good idea though, see comment above. If you revert that part, I am happy to merge get the other fixes merged.

FYI I will create a separate issue for adding a test case where something like -1, errors.New("not a scale error") is returned to encourage handling the error before evaluating the result.

FYI I will create a separate issue for adding a test case where something like -1, errors.New("not a scale error") is returned to encourage handling the error before evaluating the result.

Sounds great 👍🏼  One thing to consider though, if the fodder amount is negative and the error returned is non-ErrScaleMalfunction error then based on which part of the instructions we focus on, this can be handled in either of the following two ways.

Line 26 of the instructions specifies that in case of any non-ErrScaleMalfunction error, return the error and 0. Thus the final return value would be (0, err)
Line 36 of the instructions specifies that in case of negative fodder amount, we should return 0 and Negative fodder error.

Based on the practice of checking the error before the value, option 1 seems to the valid choice. Is there a case here for adding extra instructions to clarify the expected response? Or is the wanted output of the test case sufficient instruction for the user?

@junedev I have reverted the reordering part and only kept the minor changes as suggested.

@RajivTS Thanks a lot for being so cooperative here!
Regarding your question above: Since it is a general guideline in Go to not use the result if there was an error, I think the test would be enough guidance here. Rather than adding more instructions we should make sure the introduction (concept) includes that info about not using the result.
FYI I added 2 missing line breaks. See our markdown guidelines for reference: https://exercism.org/docs/building/markdown/markdown#h-layout


Strange Behavior when Launching Hutch Python

Looks like the newhutch-python was launched from inside the old hutch-python directory. Understandably the code got confused, but we should raise an Error and not crash
https://pswww.slac.stanford.edu/apps/portal/index.php?exper_id=794&app=elog:search&params=message:386990

This would probably be fixed for good (including similar cases) if we implemented https://github.com/pcdshub/hutch-python/issues/127.
This probably is already fixed for the current dev patch thanks to a side-effect of https://github.com/pcdshub/hutch-python/pull/126

I'll try this in -dev just to make sure

Closing old issue


Include new cairo renderer

Hello,
this PR adds a simple cairo renderer as well as a corresponding example to clay, this allows rendering directly into PNGs, PDFs, etc.
I've got it to a point where I believe it to be 'good enough' for now, it notably does not include a proper text shaping engine, instead relying on cairo's toy text API to measure text, etc.
This is flaky for some fonts, though I tweaked it that the result is acceptable for most fonts I tested it against.
Here's a preview of the PDF the example emits:
output.pdf

Thanks for all the awesome work here 🎉 just taking a look now!


Update requirements and readme

I think that the requirements are resolved (see #16), but not sure about the readme


Error trying to train using your train.php example

I am getting this error, when I am trying to train using your train.php (https://github.com/RubixML/Sentiment/blob/master/train.php) example:
Fatal error: Uncaught TypeError: Argument 3 passed to Rubix\ML\Transformers\WordCountVectorizer::__construct() must be of the type int, object given....
In your example on Line 44 you have:
new WordCountVectorizer(10000, 3, new NGram(1, 2)),
But the constuctor for WordCountVectorizer expects this:
public function __construct(
int $maxVocabulary = PHP_INT_MAX,
int $minDocumentFrequency = 1,
int $maxDocumentFrequency = PHP_INT_MAX,
?Tokenizer $tokenizer = null
)
What would be your recommended parameters for WordCountVectorizer for your example to work best?

Good catch! Did you upgrade versions recently? We added the $maxDocumentFrequency parameter in 0.1.0-rc5 ... thanks for the reminder I am going to update the train script!
Let's try a setting of 5000 for maxDocumentFrequency ... let me know if you get better results with a different setting
Also if you'd like to join our channel on Telegram https://t.me/RubixML

Should be fixed in the latest update https://github.com/RubixML/Sentiment/commit/d076d864eece25ba91c792cb6ee49917f5147216
Thanks again @bavamont!

Thank you @andrewdalpino !
I’ll try it with 5000 for maxDocumentFrequency.
Thanks again!


Alerts not showing on 5.4.11

So i am trying to at uxweb/sweet-alert to my project that is currently using 5.4.11.
I have used this on many projects before but none since i started using laravel 5.4.11
My Master Layout:
<link rel="stylesheet" href="{{url('/css/sweetalert.css')}}">
<link rel="stylesheet" href="{{url('/css/app.css')}}">
<script src="{{url('/js/sweetalert.js')}}"></script>
<script src="{{url('/js/app.js')}}"></script>
@include('sweet::alert')

My config/app.php:
UxWeb\SweetAlert\SweetAlertServiceProvider::class,
My Controller:
Alert::message('We will get back to you soon!', 'Thank you!');
return redirect()->route('home');

I have added use Auth; into my controller as well.

Have you added 'Alert' => UxWeb\SweetAlert\SweetAlert::class, to your config/app.php?

Yeah I have added both of these.

Do you receive any error messages? Might be worth trying composer dump-autoload or php artisan config:cache as mentioned in #42.

same issue here exactly with 5.3, nothing happening at all

Ran both commands, And also tested on a fresh laravel project but still not working. No errors are showing, it just doesn't display the alert.

I have just created a fresh install of laravel and included this package and everything has worked fine. Are you sure that the following is included on the layout where you want the alert to appear? Also are you sure that these files are definitely there?
`

@include('sweet::alert')`

it worked for me after putting the  @include('sweet::alert') in the Script tag i was just putting it in my view which doesnt work

@doatyjs
If PHP is not squacking for some errors, maybe this is related to the load of sweetalert assets.
Try figuring out with chrome dev tools if all your assets are being loaded

Thank you @Nathanw @ramisohail for helping @doatyjs to solve this issue 👍


Does not fit on small screen

The game works perfectly on my S3, but on the Samsung Pocket it's impossible to see the last row. I couldn't find a way to reduce zoom either.

Rather not small screens but low resolution screens (even if they are large) the bottom row is cut off.

Did you edit your layout_width or layout_height?  This could affect it.
Also, check your dimens.xml file, what does it say there?

Am afraid I dunno how to do that.


Add country in payment description

The Mollie module provides the possibilty to add  {cart.id} {order.reference} {customer.firstname} {customer.lastname} {customer.company} to the description. Is it possible to add a country code?
We have to add something here first?:
`
public static function generateDescriptionFromCart($cartId, $orderReference = '')
{
if ($cartId instanceof Cart) {
$cart = $cartId;
} else {
$cart = new Cart($cartId);
}
    $buyer = null;
    if ($cart->id_customer) {
        $buyer = new Customer($cart->id_customer);
    }

    $filters = array(
        '%'                    => $cartId,
        '{cart.id}'            => $cartId,
        '{order.reference}'    => $orderReference,
        '{customer.firstname}' => $buyer == null ? '' : $buyer->firstname,
        '{customer.lastname}'  => $buyer == null ? '' : $buyer->lastname,
        '{customer.company}'   => $buyer == null ? '' : $buyer->company,
    );

    $content = str_ireplace(
        array_keys($filters),
        array_values($filters),
        Configuration::get(static::MOLLIE_DESCRIPTION)
    );

    return $content;
}`

Hey @basemedia thank you for your suggestion,
I have backloged the ticket, will come back to you after we will discuss with the team.
Best Regards.

Advice don't install won"t work even what the develloper said, seach for a other PSP with betere payment plugins for Prestashop

Hey @basemedia sorry for a delay in this thread,
We had some intensive work regarding the 4.1.0 release and fixes, so this case for now has been put for a side a little bit. We still need to check this and approve with Mollie.
We can slightly predict that this implementation would be included somewhere in future releases but we need to discuss about this improvement with Mollie.
Thanks for your insight.
Can we close the issue for now? I can assure we have backloged this case for sure.
Best Regards.

The issue was closed, due to the inactivity for some time.
If other issues will occur, please raise a new ticket.
Best Regards.


Discourage use of RecordWildCards

This came up in Slack today, bringing it here for codification or further discussion.
The case for RecordWildCards
The RecordWildCards extension allows using .. in record patterns to bring all of a record's fields into scope, and in record-constructing expressions to implicitly pull appropriately-named values from anywhere in scope into a record value.
Record wildcards are often nice, especially in conjunction with ApplicativeDo, for codecs.
data StudentStats = StudentStats
  { assignmentType :: MathAssignmentType
  , completedAt    :: Maybe UTCTime
  , timeSpent      :: Int }

instance HasObjectCodec StudentStats where
  objectCodec = do
    assignmentType <- requiredField       "assignmentType" "" .= (.assignmentType)
    completedAt    <- optionalFieldOrNull "completedAt"    "" .= (.completedAt)
    timeSpent      <- requiredField       "timeSpent"      "" .= (.timeSpent)
    pure StudentStats {..}

They're also convenient when converting between types that share a lot of fields of the same name.
data Assignment = Assignment
  { id        :: AssignmentId
  , skill     :: RlSkill
  , createdAt :: UTCTime }

data ApiAssignment = ApiAssignment
  { id        :: AssignmentId
  , skill     :: RlSkill
  , createdAt :: UTCTime
  , title     :: Text }

toApiAssignment :: Something m => Assignment -> m ApiAssignment
toApiAssignment<EMAIL_ADDRESS>= do
  title <- getTitle x
  pure ApiAssignment{..}

The case against RecordWildCards
The biggest complaint I hear (and feel) is that the convenience of what RecordWildCards allows you to make implicit when writing code comes at the expense of what you wish were explicit when you're reading or searching the code.

When a record is destructured using .., within the pattern's scope is can be unclear which identifiers came from the record and which came from imports.
When a value is copied from one record to another using .. at both the use and binding site, it passes through without being explicitly named at all, making it difficult to search for a field's use sites.
It can make it difficult to trace and to gain a general understand what's going on by reading the code.

Some of the same convenience without the drawbacks is afforded by NamedFieldPuns, which we have enabled everywhere. Revisiting the above examples, without wildcards we can write:
instance HasObjectCodec StudentStats where
  objectCodec = do
    assignmentType <- requiredField       "assignmentType" "" .= (.assignmentType)
    completedAt    <- optionalFieldOrNull "completedAt"    "" .= (.completedAt)
    timeSpent      <- requiredField       "timeSpent"      "" .= (.timeSpent)
    pure StudentStats {assignmentType, completedAt, timeSpent}

toApiAssignment x@Assignment{id, skill, createdAt} = do
  title <- getTitle x
  pure ApiAssignment{id, skill, createdAt, title}

A separate related issue I hear (and feel) complaints about is whether we should encourage the use of more explicit import lists rather than relying on whole-module imports. It is essentially the same question - How much do you want in scope that has not been explicitly enumerated - and a very similar convenience-when-writing vs searchability-when-reading tradeoff.
The middle ground
It is an open question, I think, whether the guide should say "never use RecordWildCards" or whether we should suggest using it sparingly. In some small, focused modules I think it is mostly harmless, and would not be entirely opposed to enabling it with a LANGUAGE pragma where appropriate. If we go this route, there's then a question of whether we want to discourage RecordWildCards by turning off the extension by default, or to leave it on and simply discourage its use by verbal suggestion.

So it sounds like we have the following potential Guides:

Don't use RecordWildCards
Avoid RecordWildCards
Use RecordWildCards freely, but enable it by pragma where you do it (this PR)
Use RecordWildCards freely, and it's on by default (status quo)

I'm cool with any of these, actually. So I'll leave it to others to decide.

Seems like consensus on turning it off by default, not quite consensus on how strongly to discourage, so I'm merging just the small change.


Manual Ack in masstransite

I have handler listing to a queue  that must done one bye one and cant jump to other.
when i have error it ACK it but it didn't finished and make gap ;
code is just sample:
 cfg.ReceiveEndpoint("customer_update_queue",
                    e =>
                    {
                        e.UseMessageRetry(r => r.Immediate(5));
                        e.DiscardSkippedMessages();
                        e.DiscardFaultedMessages();

                        e.Handler<ICustomerCreated>(messageContext =>
                        {

                            return Task.Run(() =>
                            {
                                OrderContext dbcontext = new OrderContext();
                                dbcontext.Customers.Add(new Customer()
                                {
                                    Id = messageContext.Message.Id,
                                    Name = messageContext.Message.Name
                                });
                                dbcontext.SaveChanges();

                            });
                        });
                    });

is there any way ack manual?

why just not to go with:
 cfg.ReceiveEndpoint("customer_update_queue",
                    e =>
                    {
                        e.UseMessageRetry(r => r.Immediate(5));
                        e.DiscardSkippedMessages();
                        e.DiscardFaultedMessages();

                        e.Handler<ICustomerCreated>(messageContext =>
                        {

                                OrderContext dbcontext = new OrderContext();
                                dbcontext.Customers.Add(new Customer()
                                {
                                    Id = messageContext.Message.Id,
                                    Name = messageContext.Message.Name
                                });
                                dbcontext.SaveChanges();

                              return Task.Completed;
                        });
                    });

it will be retried in memory if it fails

it didn't work my problem was other thing


Shared is unavailable: use view controller based solutions where appropriate instead.

This error is occurring for me. Any suggestions?

Swift version?

yes
From: Emil Bogren<EMAIL_ADDRESS>Reply-To: Skyscanner/SkyFloatingLabelTextField<EMAIL_ADDRESS>Date: Tuesday, June 20, 2017 at 12:58 AM
To: Skyscanner/SkyFloatingLabelTextField<EMAIL_ADDRESS>Cc: Brad Gray<EMAIL_ADDRESS>Author<EMAIL_ADDRESS>Subject: Re: [Skyscanner/SkyFloatingLabelTextField] Shared is unavailable: use view controller based solutions where appropriate instead. (#150)
Swift version?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHubhttps://github.com/Skyscanner/SkyFloatingLabelTextField/issues/150#issuecomment-309675129, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AYT6NUd0fkeVdJjaed_uMlSkIrbGFJBZks5sF3uvgaJpZM4N-61C.

Hey :) What's your version of swift, deployment target and xcode version?

I'm using swift 3, deployment 10.2.

and Xcode?

xcode 8.3.3. And I think I'm actually using Swift 3.1 as that is what is needed on Xcode 8.3.3

Does this help https://stackoverflow.com/questions/34225213/uiapplication-sharedapplication-not-available?

Unfortunately no. I just check, and my my Only App Extension is set to no.

and this is a regular iOS app not an extension or module?

yep

@bradlgray01 can you reproduce this with a blank project? I'm on 8.2.1. I'll update and report back. @bogren which version are you on?

Hmm... It works on a fresh project. So strange. I guess it's my end that something is gone awry. It's fine I'll, I'll do some more research to see whats going on in my end.

Okay :) Please let me know if you figure it out :)

Will do, and thanks for your help, much appreciated .

Hi I solved this problem.
Set to Allow API Extension to No to particular framework who gives this e
error like IQKeyboardManager
Consider you facing this issue for IQKeyboardManager and you installed this framework using Pod. Then your project click on Pod -> CLick on IqkeyboardManager.
And set Allow API Extension to No

@mmmahajan You rock! Your suggestion works like a charm!

In my case, I had to remove the view controller from sources list of the Extension target instead. The extension is supposed to have this flag to YES. But my file is not intended to be part of this target.

@mmmahajan hey! Where can I find this setting? I am clicking over my framework in the Pod folder in my project.


uart: introduce TS_SECONDARY_SERIAL_PORT

(cherry picked from commit 9d8bbe38d1e63384ef0d66d3330363c894f2901b)

Is this for simultaneous BT and USB or something?

@mck1117 this is simultaneous BT and wired UART


Implement Object.assign routine

Related part of the standard: ECMA-262 v6, <IP_ADDRESS>
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik<EMAIL_ADDRESS>

Hi, is it possible to use this API at native side?

Hi @dxjia!
You can get this builtin routine from the API in the following way:
jerry_value_t global_object = jerry_get_global_object ();
jerry_value_t prop_name = jerry_create_string ((const jerry_char_t *) "Object");
jerry_value_t buitlin_object = jerry_get_property (global_object, prop_name);
jerry_release_value (global_object);
// check if `buitlin_object ` is error

prop_name = jerry_create_string ((const jerry_char_t *) "assign");
jerry_value_t object_assign_routine = jerry_get_property (buitlin_object , prop_name);
jerry_release_value (prop_name);
jerry_release_value (buitlin_object );

// check if `object_assign_routine ` is error

jerry_value_t result = jerry_call_function (object_assign_routine, <this_value>, <arguments>, arguments_length>);

jerry_release_value (object_assign_routine );

// Use `result` or check if it error
jerry_release_value (result);

I hope the following snippet helps to resolve your problem.

@rerobika
Thanks for your quick response, your suggestion is very helpful, and it works for me.
Thank you very much.


How to disable xray

How do I disable X-ray for non-AWS environments?

Hi @GnatorX,
While the X-Ray SDK can be disabled in some other languages, it cannot be disabled in Go yet. We always welcome pull requests for new features and it is our goal to move the Go SDK from rc to production with feature parity to the other SDKs.

I think the easiest way to disable X-Ray is to provide an Emiter which does nothing. In this case everything is working normally but nothing is send to the daemon. And this is what I wanted from tests.
Please correct me if this approach has any issues.
The code is really simple. I have copy/pasted it from library tests.
package xraytest

import (
	"github.com/aws/aws-xray-sdk-go/xray"
	"github.com/rs/zerolog/log"
	"net"
)

type TestEmitter struct{}

func (te *TestEmitter) Emit(seg *xray.Segment) {}

func (te *TestEmitter) RefreshEmitterWithAddress(raddr *net.UDPAddr) {}

func InitXRay() {

	err := xray.Configure(xray.Config{
		Emitter: &TestEmitter{},
	})
	if err != nil {
		log.Fatal().
			Err(err).
			Msg("Failed to initialize X-Ray.")
	}
}

Maybe we can also have a configuration option TestMode bool and when it is set to true we set TestEmitter and make the library 'silent'. I think this might be common scenario for unit tests or running application locally.

This was addressed in the latest release -- https://github.com/aws/aws-xray-sdk-go/pull/219

Released in v1.0.0 so closing this issue. Feel free to re-open for any issues.


analyze: Fix status line percentage and bytes

Abbreviate bytes in status line and correct percentage calculation.

100.0% 500.00MB/500.00MB records=670823


chore: pause bvecvx, auto earn graviaura

Codecov Report

Merging #282 (54786b0) into develop (c31b26e) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff            @@
##           develop     #282   +/-   ##
========================================
  Coverage    39.78%   39.78%
========================================
  Files           19       19
  Lines         1518     1518
========================================
  Hits           604      604
  Misses         914      914


fix peek height

Related to issue: https://devtopia.esri.com/runtime/kotlin/issues/4647
Summary of changes:

adjust peek height of bottom sheet
increase size of bottom sheet

Pre-merge Checklist

a vTest Job for this PR has been run

[x] link: https://runtime-kotlin.esri.com/view/vTest/job/vtest/job/toolkit/102/

Unit and/or integration tests have been added to exercise this PR's logic, and the tests are passing:

[ ] Yes
[ ] No


Fix mongodb-core tests to use unique DB names [AO-8024]

When running multiple matrix tests in parallel the mongo tests would cause others to fail because they all used the same database and collection names.
mongodb-core is the last of the database tests to use unique names. All the tests to depend on the environment variable AO_IX to be set - that is used to construct the unique names. Running locally there is no need to set AO_IX because only one test runs at a time. These commits just add some debugging output that allows makes it easier to see what is happening.

The environment var isn't necessary - I could use pid. I might change that in the future as it's a bit more bulletproof for situations where only a single container is restarted. I don't know why I didn't think of using pid - seems obvious right now.


Can't find USDT property - Property identifier does not exist

I've generate address in thru omnicored, and did transfer USDT to the address. But I still couldn't get the balance thru RPC API.
omni.conf

server=1
rpcuser=xxx
rpcpassword=yyy
rpcallowip=<IP_ADDRESS>/0
port=8333
rpcport=8332
txindex=1
datacarriersize=80
logtimestamps=1
omnidebug=tally
omnidebug=packets
omnidebug=pending

background run command

./omnicored -conf="./omni.conf" -datadir="/mnt/omni"

RPC API - omni_getinfo

{
"result": {
"omnicoreversion_int": 40000000,
"omnicoreversion": "0.4.0",
"mastercoreversion": "0.4.0",
"bitcoincoreversion": "0.13.2",
"block": 304578,
"blocktime":<PHONE_NUMBER>,
"blocktransactions": 2,
"totaltrades": 0,
"totaltransactions": 11024,
"alerts": []
},
"error": null,
"id": 1
}

RPC API - getaddressesbyaccount "abc"

{
"result": [
...
"1HJh8DP4hYgagUMfbUhkLJK7YtRdLQXL8",
...
],
"error": null,
"id": 1
}

RPC API - omni_getallbalancesforaddress "1HJh8DP4hYgagUMfbUhkLJK7YtRdLQXL8"
Check the address balance but return address not found, but I can found the address thru getaddressesbyaccount

{
"result": null,
"error": {
"code": -8,
"message": "Address not found"
},
"id": 1
}

RPC API - omni_listproperties
USDT not in the list

{
"result": [
{
"propertyid": 1,
"name": "Omni",
...
},
{
"propertyid": 2,
"name": "Test Omni",
...
},
{
"propertyid": 3,
...
},
{
"propertyid": 4,
...
},
{
"propertyid": 5,
...
},
{
"propertyid": 6,
...
},
{
"propertyid": 7,
...
},
{
"propertyid":<PHONE_NUMBER>,
...
},
{
"propertyid":<PHONE_NUMBER>,
...
},
{
"propertyid":<PHONE_NUMBER>,
...
},
...
],
"error": null,
"id": 1
}

RPC API - omni_getproperty 31

{
"result": null,
"error": {
"code": -8,
"message": "Property identifier does not exist"
},
"id": 1
}

Can please guide me on problem below:-

How can I get the balances of the address? Because it return "Address not found" but I can for sure the address is generate thru RPC API getnewaddress "abc"
How can have the USDT property included? I need to do send integration later on.

Hello,
can you please post the result of getinfo and omni_getinfo? I assume your client is not fully synchronized.

Hello,
can you please post the result of getinfo and omni_getinfo? I assume your client is not fully synchronized.

thanks @dexX7, below are the results as your request
getinfo

{
"result": {
"version": 130200,
"protocolversion": 70015,
"walletversion": 130000,
"balance": 0,
"blocks": 304578,
"timeoffset": -20,
"connections": 8,
"proxy": "",
"difficulty":<PHONE_NUMBER>6.90395,
"testnet": false,
"keypoololdest":<PHONE_NUMBER>,
"keypoolsize": 100,
"paytxfee": 0,
"relayfee": 0.00001,
"errors": ""
},
"error": null,
"id": 1
}

omni_getinfo

{
"result": {
"omnicoreversion_int": 40000000,
"omnicoreversion": "0.4.0",
"mastercoreversion": "0.4.0",
"bitcoincoreversion": "0.13.2",
"block": 304578,
"blocktime":<PHONE_NUMBER>,
"blocktransactions": 2,
"totaltrades": 0,
"totaltransactions": 11024,
"alerts": []
},
"error": null,
"id": 1
}


[Feature] Default to x64-windows triplet on x64 Windows

Most people don't use 32-bit builds these days, so we have to always specify the triplet which is cumbersome, or set the env-var which is not elegant.
Implementation
Instead of this:
https://github.com/microsoft/vcpkg/blob/22c8e3a23afc6be45020cd3f8c92bcea783ce8fa/toolsrc/src/vcpkg/triplet.cpp#L100
there should be a check to see if the host is 64-bit and use the x64-windows triplet if so.
IsWow64Process or IsWow64Process2 can be used for this (will work even if vcpkg is compiled as 32-bit).

Duplicated to issue https://github.com/microsoft/vcpkg/issues/1254
Related PR https://github.com/microsoft/vcpkg/pull/11610

if I have commit permission, I will change
https://github.com/microsoft/vcpkg/blob/22c8e3a23afc6be45020cd3f8c92bcea783ce8fa/toolsrc/src/vcpkg/triplet.cpp#L99-L100
to
#if defined(_WIN64)
                return Triplet::X64_WINDOWS;
#elif defined(_WIN32)
                return Triplet::X86_WINDOWS;

right now and force push it...
See how many thumb ups in #1254

@cloudhan This is wrong, _WIN64 will only check if vcpkg is compiled in a 64-bit environment, not if the host is a 64-bit operating system. If vcpkg itself was compiled as 32-bit on a 64-bit system it wouldn't work.
See my implementation recommendation above instead.

@VelocityRa Good point, and seems the bootstrap script indeed build 32bit version of vcpkg.exe on a 64bit platform. Another feature request, here you go.

This has just caught me out on a fresh install (again). 64-bit by default on 64-bit machines seems like a sensible choice.


new format of UDID for Apple Watch Series 4 is not recognised

New Issue Checklist

[x] Updated fastlane to the latest version
[x] I read the Contribution Guidelines
[x] I read docs.fastlane.tools
[x] I searched for existing GitHub issues

Issue Description

I tried to add the UDID of my Apple Watch Series 4 to the devices.txt file and create new provisioning profiles
it looks like the format changed from the 40 character hex string like
e188d1db0d434695ffc0fc51812fbdf34aca6d9b
to
00004016-002B2E022EA2001D
While it is possible to register the Watch in the Web Portal it is not possible to register it via fastlane
Complete output when running fastlane, including the stack trace and command used

[✔] 🚀
[11:04:21]: ----------------------------------------
[11:04:21]: --- Step: Verifying fastlane version ---
[11:04:21]: ----------------------------------------
[11:04:21]: Your fastlane version 2.105.2 matches the minimum requirement of 1.104.0  ✅
[11:04:21]: ------------------------------
[11:04:21]: --- Step: default_platform ---
[11:04:21]: ------------------------------
[11:04:21]: Driving the lane 'ios devices' 🚀
[11:04:21]: -----------------------
[11:04:21]: --- Step: xcversion ---
[11:04:21]: -----------------------
[11:04:22]: Setting Xcode version to /Applications/Xcode-10.app for all build steps
[11:04:22]: ------------------------------
[11:04:22]: --- Step: register_devices ---
[11:04:22]: ------------------------------
[11:04:25]: Fetching list of currently registered devices...
+------------------+-------------+
|          Lane Context          |
+------------------+-------------+
| DEFAULT_PLATFORM | ios         |
| PLATFORM_NAME    | ios         |
| LANE_NAME        | ios devices |
+------------------+-------------+
[11:04:26]: Invalid device line, please provide a file according to the Apple Sample UDID file (http://devimages.apple.com/downloads/devices/Multiple-Upload-Samples.zip)
+------+----------------------------+-------------+
|                fastlane summary                 |
+------+----------------------------+-------------+
| Step | Action                     | Time (in s) |
+------+----------------------------+-------------+
| 1    | Verifying fastlane version | 0           |
| 2    | default_platform           | 0           |
| 3    | xcversion                  | 0           |
| 4    | ./replace_commit_hash.sh   | 0           |
| 💥   | register_devices           | 3           |
| 6    | ./revert_commit_hash.sh    | 0           |
+------+----------------------------+-------------+
[11:04:26]: fastlane finished with errors
[!] Invalid device line, please provide a file according to the Apple Sample UDID file (http://devimages.apple.com/downloads/devices/Multiple-Upload-Samples.zip)

Environment

✅ fastlane environment ✅
Stack

Key
Value

OS
10.14

Ruby
2.5.1

Bundler?
true

Git
git version 2.19.0

Installation Source
/usr/local/bin/fastlane

Host
Mac OS X 10.14 (18A391)

Ruby Lib Dir
/usr/local/Cellar/ruby/2.5.1/lib

OpenSSL Version
OpenSSL 1.0.2o  27 Mar 2018

Is contained
false

Is homebrew
false

Is installed via Fabric.app
false

Xcode Path
/Applications/Xcode-10.app/Contents/Developer/

Xcode Version
10.0

System Locale

Variable
Value

LANG

LC_ALL
en_US.UTF-8
✅

LANGUAGE

fastlane gems

Gem
Version
Update-Status

fastlane
2.105.2
✅ Up-To-Date

Loaded fastlane plugins:
No plugins Loaded
Loaded gems

Gem
Version

did_you_mean
1.2.0

bundler
1.16.1

CFPropertyList
3.0.0

concurrent-ruby
1.0.5

i18n
0.9.5

minitest
5.11.3

thread_safe
0.3.6

tzinfo
1.2.5

activesupport
4.2.10

public_suffix
2.0.5

addressable
2.5.2

atomos
0.1.3

babosa
1.0.2

claide
1.0.2

fuzzy_match
2.0.4

nap
1.1.0

cocoapods-core
1.5.3

cocoapods-deintegrate
1.0.2

cocoapods-downloader
1.2.1

cocoapods-plugins
1.0.0

cocoapods-search
1.0.0

cocoapods-stats
1.0.0

netrc
0.11.0

cocoapods-trunk
1.3.1

cocoapods-try
1.1.0

colored2
3.1.2

escape
0.0.4

fourflusher
2.0.1

gh_inspector
1.1.3

molinillo
0.6.6

ruby-macho
1.2.0

nanaimo
0.2.6

xcodeproj
1.6.0

cocoapods
1.5.3

colored
1.2

highline
1.7.10

commander-fastlane
4.4.6

declarative
0.0.10

declarative-option
0.1.0

unf_ext
<IP_ADDRESS>

unf
0.1.4

domain_name
0.5.20180417

dotenv
2.5.0

emoji_regex
0.1.1

excon
0.62.0

multipart-post
2.0.0

faraday
0.15.3

http-cookie
1.0.3

faraday-cookie_jar
0.0.6

faraday_middleware
0.12.2

fastimage
2.1.4

jwt
2.1.0

memoist
0.16.0

multi_json
1.13.1

os
1.0.0

signet
0.10.0

googleauth
0.6.6

httpclient
2.8.3

mime-types-data
3.2018.0812

mime-types
3.2.2

uber
0.1.0

representable
3.0.4

retriable
3.1.2

google-api-client
0.23.9

json
2.1.0

mini_magick
4.5.1

multi_xml
0.6.0

plist
3.4.0

rubyzip
1.2.2

security
0.1.3

naturally
2.2.0

simctl
1.6.5

slack-notifier
2.3.2

terminal-notifier
1.8.0

unicode-display_width
1.4.0

terminal-table
1.8.0

tty-screen
0.6.5

tty-cursor
0.6.0

tty-spinner
0.8.0

word_wrap
1.0.0

rouge
2.0.7

xcpretty
0.3.0

xcpretty-travis-formatter
1.0.0

xcode-install
2.4.4

generated on: 2018-09-26

Yes, it is very possible that #13407 didn't touch the code you are executing or the regex doesn't match or something similar - someone will have to look into that.

I just came across the UDID format change. Running register_device worked for me with 2.105.2.

tried it again, it worked, must have been a mistake in the format of the line (tab vs. space)


Define membership

For the purposes of this package.

Not only what it can mean, but whether this can support different meanings in the same implementation.
We were talking about "membership" in the context of public radio earlier today, but the national level, member stations in relation to local, station members never came up.
While I doubt you'd need the member of member functionality at the NPR scale, other organizations have a similar model with member chapters that have individual members that could be configured in a single CRM instance.


rip protoBindings

some are being built in internal builds
anyone can build their own based on the cpg.proto which is still
being published in the schema.jar

this turns out to be more complicated than I thought, mostly because the CpgOverlay depends on the cpg proto bindings.


how to make flow group?

how to make flow group?

What do you mean with flow group?

how to make two nodes module become a group

A container contains two nodes. The two nodes can be dragged to connect

You can select multiple elements while pressing shift but you can not group elements data-wise.

This feature is not planned for now.

We now collection feature ideas in the "Discussions/New Features" section #1022


Consistent Docker Buildx Action Version

Changed the Docker Buildx action version in the nethermind job to v4 to match the others AND Ensured consistent indentation for better readability.
These changes should improve the workflow's consistency and clarity

🟡 Heimdall Review Status

Requirement
Status
More Info

Reviews

🟡
0/1

Denominator calculation

Show calculation

1 if user is bot
0

1 if user is external
0

From .codeflow.yml

1

Additional review requirements

Show calculation

Max
0

0

From CODEOWNERS

0

Global minimum
0

Max

1

1

1 if commit is unverified
0

Sum
1


(WIP): Add Gardener Extension support for Cilium Networking

Add support for Cilium Networking to gardener-extension-networking-cilium.
Cilium is open source software for transparently securing the network
connectivity between application services deployed using Linux container
management platforms like Docker and Kubernetes that depends on the new
Linux kernel technology called BPF.
Fixes: #129
Signed-off-by: Swaminathan Vasudevan<EMAIL_ADDRESS>

closing in favor of #7


Close app window with CMD+SHIFT+W

Would be awesome if we could use CMD+SHIFT+W to close the window app. Other keyboard shortcuts are also welcome ;)
Thanks!

I thought cmdw was the default for that? Or is that based on locale?

Different apps use different shortcuts ie. In some cmd+w closes the current conversation while cmd+shift+w closes the app window.
Dnia 9 kwi 2015 o godz. 08:49 Peter Renström<EMAIL_ADDRESS>napisał(a):

I thought cmdw was the default for that? Or is that based on locale?
—
Reply to this email directly or view it on GitHub.

Added cmd+w to close!


Add this kubesphere-authz middleware to the official list

We have several options to integrate this repo into the kubesphere ecosystem, like code integration, listing in the 3rd-party authorization middleware list, etc. See how we did it for apisix middleware: https://github.com/casbin-lua/apisix-authz/issues/5

@ComradeProgrammer


BUG: No spacing to the left of the page

The content on the website is too close to the left edge of the screen, making it look cramped. Adding some space (padding or margin) on the left side to make the page look more balanced and easier to read. This will improve the user experience and make the layout look better.
This is the image

Can you assign this to me under the labels gssoc and hacktoberfest
I would like to fix this

I have already raised a PR for this kindly checkout.