WebSocket Questions

Hello,
I am new to Javalin and WebSockets, and I have a couple of questions:
After establishing the ws connection, I am able to send a few messages but the socket seems to disconnect when it becomes idle for a few seconds. Is there a way to keep the connection open?
I would like to have a java thread for each web socket connection, how can I make it so that the same thread keeps receiving the corresponding websocket messages?
Thanks,

You can enable automatic pings to keep the connection open, you can find this in the docs.
Could you explain why you want this?

Thank you for your response.

I called enableAutomaticPings() in the onConnect(ctx), but the connection continues to disconnect after about 20 seconds. Is there a way to access the Jetty setIdleTimeout() function.

The existing system uses sticky sessions which point to a specific server/session where state is stored. I am exploring using Javalin and WebSockets but making minimal application changes.

Thanks again,

I called enableAutomaticPings() in the onConnect(ctx), but the connection continues to disconnect after about 20 seconds. Is there a way to access the Jetty setIdleTimeout() function.

Yes, through config.jetty (https://javalin.io/documentation#jettyconfig), but are you sure this is what you're seeing? Are you running behind some sort of proxy?

The existing system uses sticky sessions which point to a specific server/session where state is stored. I am exploring using Javalin and WebSockets but making minimal application changes.

Hmm.. If you have two instances, and a WebSocket client connects to one instance, all messages should always go over that connection without you having to do anything.

Hello,

I am not using a proxy. I changed it to enableAutomaticPings(5, TimeUnit.SECONDS) and that works as expected.

I have the following code:
.ws("/ws", ws -> {
ws.onConnect(ctx -> {
ctx.enableAutomaticPings(5, TimeUnit.SECONDS);
console("Connected");
// (A)
Worker worker = New Worker();
});
ws.onMessage(ctx -> {
// (B)
worker.push(ctx);
});
ws.onClose(ctx -> console("WS Closed"));
})

Let's say that I want to start a worker thread that will take a long time to complete and should process all the messages that are received on its corresponding websocket.  If I start the worker thread (A), how can it be made accessible in (B).
Thanks,

Glad you got 1 sorted.
For 2, there is an ID for the WebSocket session available through ctx.getSessionId(), is this enough to solve your use case?

Yes, thank you very much.


Azure Blob Storage Image optimization stops working invalid media ID

We get an issue after installing azureblobstorage plugin and changing the imageoptimizer config settings as described in the documentation here:
https://github.com/umbraco-community/UmbracoFileSystemProviders.Azure under combining with Imageprocessor.
We changed security.config to:
<service name="LocalFileImageService" type="ImageProcessor.Web.Services.LocalFileImageService, ImageProcessor.Web"/>     <service prefix="local/" name="CloudImageService" type="ImageProcessor.Web.Services.CloudImageService, ImageProcessor.Web">       <settings>         <setting key="MaxBytes" value="8194304"/>         <setting key="Timeout" value="30000"/>         <setting key="Host" value="https://xx.blob.core.windows.net/local/"/>       </settings>     </service>
We have a container in there called local, development, etc.
When we try hitting reoptimize image, for an existing file, we get an error:
An unexpected internal error has occurred; the image could not be optimized
after that, the folder and file disappears from the local media folder, and we get an invalid media id error on any subsequent calls to re-optimize.
For new images, it's straight to Invalid Media Id. Feels like it's still looking for the image in the local path.
What do you think we are doing wrong with this? Our cache config hasn't changed:
 <cache name="DiskCache" type="ImageProcessor.Web.Caching.DiskCache, ImageProcessor.Web" maxDays="365" browserMaxDays="7" trimCache="false" memoryMaxMinutes="1">       <settings>         <setting key="VirtualCachePath" value="~/app_data/cache" />       </settings>     </cache>
We use

ImageProcessor version: <IP_ADDRESS>
ImageProcessor.Web version: <IP_ADDRESS>
ImageProcessor.Web.Config version: <IP_ADDRESS>

Thank you

We get an issue after installing azureblobstorage plugin and changing the imageoptimizer config settings as described in the documentation here:

What imageoptimizer config?

wrong project?


Error in safari when running as web worker

As described in #482 there's a problem running local forage in a safari web worker.
Unfortunately there seems to be a Safaribug (at least in Safari 9) where running something like the following as a web worker results in this being undefined.
'use strict';
(function() {
  self.postMessage(typeof this); // `this` is undefined
}).call(self);

It only happens in strict mode (i.e. remove the 'use strict' and everything is OK). This PR works around the issue by passing in the global variable directly (rather than using call)

Babel will add the 'use strict'; statement anyway (since ES6 modules run in strict mode) so :+1: for your IIFE transformation :smile:


example: hibench spark benchmark

The workflow:

Build a docker image containing spark/hibench.
Push image to docker hub.
Allocate resources on Google or AWS.
Using the Ansible action, execute benchmark and retrieve result files.

As far as I understood about this workflow, for step 1  I'll have to create a repo similar to this but it would be installing HiBench to run spark benchmarks, the Setup section from here would be followed to create the Dockerfile?
After that, there would be a workflow something like this:
workflow "get code" {
  on = "push"
  resolves = ["Docker push"]
}

action "Docker build image" {
  uses = "actions/docker/cli@master"
  args = "build -t arshul/spark-hibench ."
}

action "Docker Login" {
  uses = "actions/docker/login@master"
  secrets = ["DOCKER_USERNAME", "DOCKER_PASSWORD"]
  needs = ["Docker build image"]
}

action "Docker push" {
  uses = "actions/docker/cli@master"
  needs = ["Docker Login"]
  args = "push arshul/spark-hibench"
}

This would complete the two step of the workflow you mentioned. Am I going in the righ direction?

hey @arshul, yes, that would work for the first two steps!


v<IP_ADDRESS>

Once this is approved, I'll tag this and release to Rubygems.

Happy to see this released! Let me know if you need to be added as an owner on RubyGems. 🚢

@mrgilman Can you add<EMAIL_ADDRESS>as a gem owner?

@gabebw done!


Release 3.1.0

3.0.1 was released the 29th of August, but we also forgot to update the browser version to the new name.   The commits below include that update.   Should we release a new patch release soon with that change?  I don't think there are any commits below that need a minor bump.  I can see an argument for a7e0aa0 as a minor bump,  but I don't think it needs to be
git log v3.0.1..origin/master --oneline

a7e0aa0 lib: expose constants in a more intuitive way (#299)
bc81242 build(deps): bump elliptic from 6.5.2 to 6.5.3 (#290)
31c2005 refactor: no import star (#297)
48d182b fix: update browser name to cloudevents. (#292)
763838c chore: Update examples to use latest sdk changes (#282)
3fab5f2 docs: update badge name (#289)
ed9ea95 fix: ensure that data encoded as base64 is parsed as an object (#285)
e219a30 chore: Update readme with correct Receiver usage (#287)

3.0.1 was released the 29th of August

That's some powerful time machine work you've got there! :laughing:

+1 for a new release

That's some powerful time machine work you've got there! laughing

:facepalm:

@lholmquist thinking a bit more about this, I think maybe this warrants a 3.1.0 release. The change with CONSTANTS being exported is a breaking change, and will actually break an automated upgrade.

@lance that is fine.

lets make sure this makes it in too, https://github.com/cloudevents/sdk-javascript/pull/302

Updating the list of commits:
git log v3.0.1..origin/master --oneline

a5249de chore:  fix promise tests to break the build when they fail (#305)
ad0c434 fix: Add Correct Headers to emitted Binary Event (#302)
a7e0aa0 lib: expose constants in a more intuitive way (#299)
bc81242 build(deps): bump elliptic from 6.5.2 to 6.5.3 (#290)
31c2005 refactor: no import star (#297)
48d182b fix: update browser name to cloudevents. (#292)
763838c chore: Update examples to use latest sdk changes (#282)
3fab5f2 docs: update badge name (#289)
ed9ea95 fix: ensure that data encoded as base64 is parsed as an object (#285)
e219a30 chore: Update readme with correct Receiver usage (#287)

So doing a npm run release -- --dry-run  the version that was created, was 3.0.2 based on the commits.
@lance @grant I think we might need to force a 3.1.0 if we feel #299 makes it a minor bump instead of a patch bump

@lholmquist I think we should... You may know how already, but it's pretty easy to force a version number.
npm run release -- --release-as 3.2.0

yup,  i am familiar

There have been a couple commits that came in today, which were doc and some process related things,  3.1.0 is now looking like:
08bf15d  docs: Release Guidelines (#306)
f3cc2b4 chore: update the release script to signoff the commit (#307)
a5249de chore:  fix promise tests to break the build when they fail (#305)
ad0c434 fix: Add Correct Headers to emitted Binary Event (#302)
a7e0aa0 lib: expose constants in a more intuitive way (#299)
bc81242 build(deps): bump elliptic from 6.5.2 to 6.5.3 (#290)
31c2005 refactor: no import star (#297)
48d182b fix: update browser name to cloudevents. (#292)
763838c chore: Update examples to use latest sdk changes (#282)
3fab5f2 docs: update badge name (#289)
ed9ea95 fix: ensure that data encoded as base64 is parsed as an object (#285)
e219a30 chore: Update readme with correct Receiver usage (#287)

Released now as 3.1.0, https://www.npmjs.com/package/cloudevents/v/3.1.0


binary.Read (or a new call) should return number of bytes read

Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (go version)?
1.7.4
What operating system and processor architecture are you using (go env)?
linux/amd64
linux/arm
darwin/amd64
What did you do?
I want to use binary.Read() to marshall data to/from network byte-order.
I must keep track of my offset from the beginning of the stream (I'm decoding DNS records, which sometimes refer to strings found at offsets-from-0 farther back as a form of compression).
I would prefer not to require the use of an io.ReadSeeker just for the sake of discovering my current offset.
What did you expect to see?
I expected binary.Read() to return the number of bytes read, as all of the io.Read implementations do.
What did you see instead?
It doesn't! This seems like a silly oversight, but also not a big or difficult change.
I created a trivial library to replace the function. In retrospect, it would be better to have a differently-named function in the upstream Golang binary package so that Go-1.x compatibility isn't broken. binary.Read could be a wrapper which just drops the bytesRead return value.

Whether or not the API is a mistake, it's frozen now, as you've noted.
The other possibility is you can pass in an io.Reader wrapper that counts how many bytes have been read through it.
It doesn't seem worth adding more API to the package at this point.

@bradfitz somehow that possibility hadn't occurred to me, guess I'm still getting used to satisfying interfaces.
The workaround will definitely suffice but I still hate the inconsistency. Is there a Wish List of things the Go team would like to get more right in a Go-2.0, if such a thing ever comes to be?
Thanks for the swift response!

The wishlist is issues with the "go2" label.

@ianlancetaylor can we add that label here, rather than closing it as a "let's never fix that"?

@sayotte Done.


FSharp.Build project does not load on latest master

aha, this required F# Desktop support, which I did not have.

Nope, that's not it:

@KevinRansom looks like this was last touched with #5425 - any idea why this could be failing to load in the solution?


fix fires in CI

the great fire of 2023 post paris offsite

https://app.zenhub.com/workspaces/velocity-62264fddc441a100183f7f86/issues/gh/minaprotocol/mina/13282


Entity Framework Relationship Fix-up Failure

For the below code, the expected behavior of EF is to commit order and the orderItem with orderID=100 and as far as I know, this auto assignment of the field orderID is known as relatinship fix-up. So, we do not have to provide the orderID field for the orderItem to be added.
        Entities ctx = new Entities();

        Order order = new Order()
        {
            ID = 100,
            name = "abc"
        };

        // ID field of OrderItem is auto-increment and the primary field
        //OrderItem is a navigation property of Order through the orderID field
        OrderItem orderItem = new OrderItem ()
        {
            name = "oi_abc"
        };
        order.OrderItems.Add(orderItem);

        ctx.Orders.Add(order);
        ctx.SaveChanges();

This piece of sample code works as expected. But the problem is, a similar piece of code in our project fails to do proper relationship fix-up. (I know it would be best if I could provide the whole code but it is impossible due to other complexities of the code and database and also due to our company policy.)
The code in our project simply sets orderID as 0 during commit.
Some important things to note:

We do not disable tracking changes of the context anywhere
Setting orderID manually works but it is not desired for us
If we have the ctx.Orders.Add(order); line right after creating the order object, then it work as expected.

 Especially given the third bullet point, can this be a bug?

@john-larson The only thing that comes to mind is that fixup does not work fully when the same property is shared my multiple FKs. Other than that, it could be a bug, but we would need code to reproduce the behavior in order to confirm this.

@ajcvickers Thanks for the prompt response.

The only thing that comes to mind is that fixup does not work fully when the same property is shared my multiple FKs.

How can I check if this is the case?
I also tried to debug using the EF source code but to no avail. I guess the relevant code is inside the ObjectStateManager.DetectChanges method but the property in the dependent entity does not change before all is committed, so I could not figure out what to look for during the DetectChanges method.

@john-larson It should be apparent from the model if the same property is being used in multiple foreign keys, either in the Code First configuration or in the EDMX, depending which you are using.

We are using db first edmx. Going by the sample code I provided, double click the OrderItem entity, clicking on the Navigation properties in the diagram shows the property used and only the Order navigation property uses the orderID property. Is this what you meant I should check?

@john-larson It didn't occur to me to look at it in the designer, but yes that should be the same as looking directly in the EDMX.

EF Team Triage: Closing this issue as the requested additional details have not been provided and we have been unable to reproduce it.
BTW this is a canned response and may have info or details that do not directly apply to this particular issue. While we'd like to spend the time to uniquely address every incoming issue, we get a lot traffic on the EF projects and that is not practical. To ensure we maximize the time we have to work on fixing bugs, implementing new features, etc. we use canned responses for common triage decisions.


Hide expandable trigger labels in no-js state

"Show"/"Hide" labels for expandables should be added with JS so they don't appear when in no-js state.
Current behavior

"Show"/"Hide" labels show up when JS is disabled.

Expected behavior

"Show"/"Hide" labels do not appear when JS is disabled.

Steps to replicate behavior

Turn off JS
Visit https://cfpb.github.io/capital-framework/components/cf-expandables/
Note both expandable trigger labels show up.

Screenshots
Current

I think we used to hide them entirely with the no-js class. We could use that for a quick fix and add injection to the backlog for when someone has some time to spare.

Sure 👍

In cfgov-refresh, the template has .u-hidden on those links by default, which gets removed by JS when initializing. One more thing to reconcile when we move cfgov-refresh to CF's expandables 😬

This was fixed in #787


C++ code generation: check composite and bitset version

Previously, the C++ generated code did not check the version before writing composite and bitset fields to the output stream. This leads to undefined behavior. I've updated the generated code to first check if the field is in the acting version before writing it to the stream.

I'm good with this assuming it passes the build.


Hubble Link API returns incorrect data

What is the bug?
The Hubble link API returns a 400 even if there is a valid link between the provided FIDs. The Link API returns a 200 with data if a link is found else returns a 400. My app was using this to check if person A followed person B on Farcaster.
How can it be reproduced? (optional)
my farcaster account (FID: 2483) follows Dan (FID: 3), the following curl command should return a 200
curl https://hub.pinata.cloud/v1/linkById\?fid\=2483\&target_fid\=3\&link_type\=follow | jq

instead it returns a 400 error as in the screenshot below:

I am seeing the same. E.G. both wake (2904) and I (18513) follow each other.
This returns all my follows including wake
/linksByFid?fid=18513

This returns all wake's follows including me
/linksByFid?fid=2904

This returns the same error as dawksh ('Link Add Message not found for 18513' or 2904 if i swap fid/target_fid values in the request).
/linkById?fid=18513&target_fid=2904&link_type=follow returns

Should be fixed by https://github.com/farcasterxyz/hub-monorepo/pull/1994

Closing as fixed. Let us know if you're still seeing this issue after upgrading to Hubble 1.12.2. Thanks!


prepareAsync() doesn't work

I created a hybrid player in my service.
When I do this:
       mMediaPlayer.reset();
       try {
            mMediaPlayer.setDataSource(source);
            mMediaPlayer.prepareAsync();
       } catch (IOException e) {
            Log.i(TAG, "mMediaPlayer setDataSource e: " + e);
       }

        ....

       @Override
       public boolean onError(IBasicMediaPlayer mp, int what, int extra) {
           Log.i(TAG, "MediaPlayer: onError " + " " + what + " " + extra);
           return false;
       }

It just instantly calls onError  & onCompletion and tries to play the next song, fails again with the same error and so on
04-29 20:13:56.809 26389-26389/com.android.testpalyer E/OpenSLMediaPlayer: An error occurred in getCurrentPosition()
04-29 20:13:56.815 26389-26389/com.android.testpalyer I/LOGGG: MediaPlayer: onError  -38 0
04-29 20:13:56.815 26389-26389/com.android.testpalyer I/LOGGG: MediaPlayer: onCompletion
04-29 20:13:56.890 26389-26389/com.android.testpalyer I/LOGGG: MediaPlayer: onError  -38 0
04-29 20:13:56.890 26389-26389/com.android.testpalyer I/LOGGG: MediaPlayer: onCompletion
04-29 20:13:56.977 26389-26389/com.android.testpalyer I/LOGGG: MediaPlayer: onError  -38 0
04-29 20:13:56.979 26389-26389/com.android.testpalyer I/LOGGG: MediaPlayer: onCompletion
04-29 20:13:57.059 26389-26389/com.android.testpalyer I/LOGGG: MediaPlayer: onError  -38 0
04-29 20:13:57.060 26389-26389/com.android.testpalyer I/LOGGG: MediaPlayer: onCompletion
04-29 20:13:57.157 26389-26389/com.android.testpalyer I/LOGGG: MediaPlayer: onError  -38 0
04-29 20:13:57.159 26389-26389/com.android.testpalyer I/LOGGG: MediaPlayer: onCompletion

And when I run mMediaPlayer.prepareAsync(); in new Thread, then everything is ok, but I don't think this is a normal solution, this should work without creating any new threads (like with default android mediaplayer)
mMediaPlayer.reset();
        try {
            mMediaPlayer.setDataSource(source);
            new Thread(new Runnable() {
                @Override
                public void run() {
                    mMediaPlayer.prepareAsync();
                }
            }).start();
        } catch (IOException e) {
            Log.i(TAG, "mMediaPlayer setDataSource e: " + e);
        }

I also confirm that prepareAsync() not always invoke the onprepared() method
But we should be able to solve this problem creating byself the prepareAsync using player.Prepare() into  Asynctask doInBackground() and the player.Start() into Asynctask OnPostExecute(). In this way, we would simulate prepareAsync()

@anonym24 @SluggedGerm2 Hi. Sorry for the late response 😞 I tried to reproduce it today, but it cannot be done yet. Could you provide a sample project which can reproduce the issue?

04-29 20:13:56.809 26389-26389/com.android.testpalyer E/OpenSLMediaPlayer: An error occurred in getCurrentPosition()
04-29 20:13:56.815 26389-26389/com.android.testpalyer I/LOGGG: MediaPlayer: onError  -38 0

This seems that you are calling getCurrentPosition() method in wrong state. Please refer to the "Valid and invalid states" table on the official MediaPlayer document.

public OpenSLMediaPlayer player;
    private OpenSLMediaPlayerContext openSLMediaPlayerContext;
    public Song nextSong;
    private Song actual_playing;

    public customPlayer(Context context){
OpenSLMediaPlayerContext.Parameters parameters = new OpenSLMediaPlayerContext.Parameters();
        parameters.streamType = AudioManager.STREAM_MUSIC;
        openSLMediaPlayerContext = new OpenSLMediaPlayerContext(context,parameters);
        player = new OpenSLMediaPlayer(openSLMediaPlayerContext,Settings.OPTION_USE_FADE);
        player.setOnPreparedListener(new OnPreparedListener());                                     //I add one single time the prepared listener

        nextSong = null;

        actual_listSong = new ArrayList<>();
    }

class OnPreparedListener implements IBasicMediaPlayer.OnPreparedListener{
        @Override
        public void onPrepared(IBasicMediaPlayer mp) {
            mp.start();
        }
    }

private void playSong(final Context context, final Song song){
if (player == null) {   //create the player if it is null
            new customPlayer(context);
        } else {
            player.reset(); //reset the player anyway. If it is playing, or has finished to play, setdatasource wan't crash without the reset of mediaplayer
            //player.setOnPreparedListener(new OnPreparedListener()); //I tried here to reset the player,but didn't work
        }
        Uri contentUri = ContentUris.withAppendedId(android.provider.MediaStore.Audio.Media.EXTERNAL_CONTENT_URI, song.getID());
        if (contentUri == null) {
            Log.i(LOG_TAG,"Error finding the media Id : " + song.getTitle() + " - " + song.getID());
            return;
        }

        setNextSong();  //update the next song

        try {
            player.setDataSource(context,contentUri);
            player.prepare();
            player.start();
        } catch (IOException e) {
            e.printStackTrace();
            Toast.makeText(context,e.getMessage() + " (" + actual_playing.getTitle() + ")",Toast.LENGTH_LONG).show();
        }
}

Usync prepareAsync() the OnPrepared is called the first time but not the following. For this reason i'm using normal prepare()
I also tried to create an asynctask and simulate the prepareAsync() but didn't work, some error occured

@SluggedGerm2 Thanks, but it cannot be reproduced yet on my setup. Could you try the following repository, it is a simple sample project based on your code.
https://github.com/h6ah4i/openslmediaplayer_issue_40
My setup:

Nexus 5X  +  Stock Android 7.1.2

Your sample works :/ why?

@h6ah4i
for me my own project seems to be working ok now, not sure what happened
I tried 0.7.3 & 0.7.5 and both worked ok.
I'll let you know if issue happens again and upload example

@h6ah4i: I have updated my project from 0.7.3 to 0.7.5 and now the prepareAsync() is called some times, but still not always. I can't see anything common for songs that never arrived to OnPreparedListener.
The same song sometimes works and other time not. I thought that cold be the thread that simultaneasly try to read the the song cover art, but also disabling this thread prepareAsync doesn't work. Disabling this thread there isn't anything more can interfare with song prepare, i think
For example now I'm trying to play always same two songs. Sometimes both works, sometimes only one, and sometimes none works.

I guess I quite understood the problem, so mb it really because of calling such method like .getDuration , .getCurrentPosition in wrong state (e.g. before source song was prepared).
And it seems that OpenslMediaPlayer calls onCompletion method when these errors happens - here I guess the difference between OpenslMediaPlayer &  Default Android MediaPlayer.
So for Default Android MediaPlayer these errors weren't critical, it didn't call onCompletion and there was no any loop with fast switching to next song (in onCompletion method I call my 'nextSong' method)

yes, now I'm sure. If we for example call mMediaPlayer.getCurrentPosition() while something is being prepared async (with prepareAsync method), OpenslMediaPlayer will call onError and onCompletion

@anonym24 Thanks for this clarification! now I can try to avoid this problem :)

I solved with a simple boolean that is setted to false when setDataSource is setted (so before prepareAsync) and is setted to true when the Onprepared is called. So I ovveride dangerous methods like getCurrentPosition() to make it only working if the boolean is true

@SluggedGerm2 yeah I did exactly the same :)

@anonym24 @h6ah4i Thanks a lot for your kind help

@anonym24 @h6ah4i @SluggedGerm2  Is there anyone to guide me for the same.
Actually I'm also facing the same scenario even after performing the above suggestions
fun startSong() {
mHandler?.removeCallbacks(sendUpdatesToUI)
    mSong = mSongs[mSongPos]
    mMediaPlayer1?.reset()
    mMediaPlayerPrepared = false
    try {
        mSongDataHelper = SongDataHelper()
        mSongDataHelper?.populateSongData(mContext!!, null, mSongPos)
        mMediaPlayer1?.setDataSource(mContext!!, getUri(mSongs[mSongPos]._id!!))
       mMediaPlayer1?.setOnPreparedListener(onPreparedListener)
        mMediaPlayer1?.setOnErrorListener(onErrorListener)
        mMediaPlayer1?.prepareAsync()

    } catch (ex: Exception) {
        ex.printStackTrace()
    }
}

/* Prepared Listener */
private val onPreparedListener =
IBasicMediaPlayer.OnPreparedListener {
mMediaPlayerPrepared = true
mMediaPlayer1?.setOnCompletionListener(mOnCompletionListener)
if (mPlayingForFirstTime) {
mPlayingForFirstTime = false
}
startPlaying()
        val intent = Intent(Constants.ACTION_UPDATE_NOW_PLAYING_UI)
        intent.putExtra(Constants.UPDATE_UI, true)
        sendBroadcast(intent)
    }

@anonym24 @h6ah4i @SluggedGerm2 Is there anyone to guide me for the same.
Actually I'm also facing the same scenario even after performing the above suggestions
And my audio glitches if I perform prepare()
fun startSong() {
mHandler?.removeCallbacks(sendUpdatesToUI)
    mSong = mSongs[mSongPos]
    mMediaPlayer1?.reset()
    mMediaPlayerPrepared = false
    try {
        mSongDataHelper = SongDataHelper()
        mSongDataHelper?.populateSongData(mContext!!, null, mSongPos)
        mMediaPlayer1?.setDataSource(mContext!!, getUri(mSongs[mSongPos]._id!!))
       mMediaPlayer1?.setOnPreparedListener(onPreparedListener)
        mMediaPlayer1?.setOnErrorListener(onErrorListener)
        mMediaPlayer1?.prepareAsync()

    } catch (ex: Exception) {
        ex.printStackTrace()
    }
}

/* Prepared Listener */
private val onPreparedListener =
        IBasicMediaPlayer.OnPreparedListener {
            mMediaPlayerPrepared = true
            mMediaPlayer1?.setOnCompletionListener(mOnCompletionListener)
            if (mPlayingForFirstTime) {
                mPlayingForFirstTime = false
            }
            startPlaying()

            val intent = Intent(Constants.ACTION_UPDATE_NOW_PLAYING_UI)
            intent.putExtra(Constants.UPDATE_UI, true)
            sendBroadcast(intent)
        }

Wonderfull. Thanks


How to use go-zookeeper create PERSISTENT znode?

I just saw the only two Flags "FlagEphemeral and FlagSequence" but no one like FlagPersistent.
Which Flag to use when call the Conn.Create(path string, data []byte, flags int32, acl []ACL) function?

i found that !
set the parameter flags to 0 when call the function
……——……


Extra Space

Not a big issue but where a Data Element “is the same as attribute” there is a space after the attribute name and the full stop, e.g.

CANCER PROGRESSION (ICD)
ACCOMMODATION STATUS CODE

Not urgent

I think this is a James one.  I've just looked at the HTML I send to James and there doesn't appear to be any spaces, so I'm guessing its an artefact of replacing the 'a' tag with an internal link.
CANCER_PROGRESSION_(ICD_ORIGINAL) is the same as attribute CLINICAL_CLASSIFICATION_CODE.
ACCOMMODATION_STATUS_CODE is the same as attribute ACCOMMODATION_STATUS_CODE.

(of course it rendered the html.  fml.  apologies)

In the DITA file the full stop appears on next line
CANCER PROGRESSION (ICD ORIGINAL)
 is the same as attribute
CLINICAL CLASSIFICATION CODE
.
Have assigned to both Nicholas and James - as css might be able to handle?

This may also be same issue as #8

This appears to have been fixed, can it be closed?


Supprort request spnego enabled Yarn resource restful interface When Yarn enable kerberos

Problem Description:
The company's big data platform environment is HDP, and Kerberos is enabled. By default, it cannot directly access http://xx.xx.xx.xx:8088  of yarn. When I use spark  engine, the Existing certification methods can not meet the requirements and always report errors
Solution:
add utils to solution of httpclient requets to request kerberos web

@Zosimer

@Zosimer


render ipywidgets.HTML()

If a python notebook cell contains e.g. display(ipywidgets.HTML("Hello")), ideally nbsphinx should keep the raw HTML. Is there any other way a python code cell (not markdown cell) can use raw HTML?

What do you mean by "keep the raw HTML"?
When I run the given code, the formatted text "Hello" is displayed, the  markup is not visible (but is taken into account by the browser).
When I do the same with nbsphinx, the output is the same.

Is there any other way a python code cell (not markdown cell) can use raw HTML?

from IPython.display import HTML
display(HTML("Hello"))

This produces a very similar result, but it doesn't need the widgets machinery.

Intriguing... display(IPython.display.HTML("Hello")) works but display(ipywidgets.HTML("Hello")) gets stripped by nbsphinx.
In both cases saving & reopening the notebook works as expected; it just seems that nbsphinx removes ipywidgets upon conversion.

I can't reproduce anything getting stripped by nbsphinx.
Do other Jupyter widgets work with nbsphinx?
You can use this notebook for testing: https://nbsphinx.readthedocs.io/en/0.8.3/code-cells.html#Interactive-Widgets-(HTML-only).
If it doesn't work, you should have a look at https://nbsphinx.readthedocs.io/en/0.8.3/code-cells.html#Troubleshooting.


Allow float zooms

This takes all changes from @orionstein and updates the tests to remove constants and test against float values like 4.00000001
This will go out in a new minor version, 1.1.0
cc @flippmoke @tristen

@mapsam Thanks, sorry for not getting back to those, I had worried about one of the tests, but I think it was fine

@orionstein no worries at all - which test were you worried about?


Can update for swift 4.2 ?

I’ll review this during the weekend, and get a new build out.

has been updated, thanks


Add swipeable actions to recycler actions

Very strange. UI tests passed on the firebase, but CircleCI didn't get any response and failed with timeout after 10 minutes. I'll continue investigation.

@jkaan Can you please merge changes from master to your branch so that we can trigger CI again?

@Alviere Of course. I've done so now.

Not sure why the RecyckerView And ScrollView need swipe actions. Could you please explain? @jkaan

@VerachadW I've had a test where I wanted to test that the moment that you start scrolling a certain event was triggered. I implemented that behaviour using a scroll listener on the recyclerview and the scrollTo functions on the RecyclerViewActions do not trigger the scroll listener.


Delete increase/decrease supply events

UtilityTokenInterface should not emit specific events when the supply increases or decreases. Instead, this information should be taken from transfer events that transfer from or to the zero-address.

This is already done in #499


about model_deployment's  front source code , have open?

i only find them in nginx CONTAINER /etc/nginx/web ，but it's already build，can i take source code?
@phoenix-xhuang

@pubalglib

model_deployment is not open source.

thanks bro


Dashboard OTF Staff: Stats block

[ ] Add to dash
review
project
RFP
[ ] Count as per review, project and RFP querysets on page
[ ] Block should link to title of relevant table heading anchor in dashboard page

Invision - https://projects.invisionapp.com/d/main?origin=v7#/console/17925572/372449580/preview
Status Block

Submissions Waiting Your Review

Queryset Count: As per existing Queryset for Review table

Live Projects under your management

Queryset Count: As per new Your Projects table

Requests for Payment Requiring your attention

Queryset Count: As per new Active Requests For Payment table

Dependent on #1463 for queryset count

Acceptance criteria visible and functional. Thanks!


pachyderm: 2.9.5 -> 2.10.1

Automatic update generated by nixpkgs-update tools. This update was made based on information from https://github.com/pachyderm/pachyderm/releases.
meta.description for pachyderm is: Containerized Data Analytics
meta.homepage for pachyderm is: https://www.pachyderm.com/
Updates performed

Golang update

To inspect upstream changes

Release on GitHub

Compare changes on GitHub

Impact
Checks done

built on NixOS
The tests defined in passthru.tests, if any, passed
found 2.10.1 with grep in /nix/store/wsy68wsqcf3vrid2fm755ld71zgpb5m2-pachyderm-2.10.1
found 2.10.1 in filename of file in /nix/store/wsy68wsqcf3vrid2fm755ld71zgpb5m2-pachyderm-2.10.1

Rebuild report (if merged into master) (click to expand)

2 total rebuild path(s)

2 package rebuild(s)

First fifty rebuilds by attrpath

pachyderm

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/wsy68wsqcf3vrid2fm755ld71zgpb5m2-pachyderm-2.10.1 \
  --option binary-caches 'https://cache.nixos.org/ https://nix-community.cachix.org/' \
  --option trusted-public-keys '
  nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(The Cachix cache is only trusted for this store-path realization.)
For the Cachix download to work, your user must be in the trusted-users list or you can use sudo since root is effectively trusted.
Or, build yourself:
nix-build -A pachyderm https://github.com/r-ryantm/nixpkgs/archive/59a29eef1ab56decdbcfdec84b48f4f6d6a93e19.tar.gz

Or:
nix build github:r-ryantm/nixpkgs/59a29eef1ab56decdbcfdec84b48f4f6d6a93e19#pachyderm

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/wsy68wsqcf3vrid2fm755ld71zgpb5m2-pachyderm-2.10.1
ls -la /nix/store/wsy68wsqcf3vrid2fm755ld71zgpb5m2-pachyderm-2.10.1/bin

Pre-merge build results
We have automatically built all packages that will get rebuilt due to
this change.
This gives evidence on whether the upgrade will break dependent packages.
Note sometimes packages show up as failed to build independent of the
change, simply because they are already broken on the target branch.
Result of nixpkgs-review --extra-nixpkgs-config '{ allowInsecurePredicate = x: true; }' run on x86_64-linux 1

1 package built:

pachyderm

Maintainer pings
cc @offlinehacker for testing.

Result of nixpkgs-review pr 314818 run on x86_64-linux 1

1 package built:

pachyderm


[MINOR][SQL] Rename isTemporaryTable to isTempView in SessionCatalog

What changes were proposed in this pull request?
Rename SessionCatalog.isTemporaryTable() to SessionCatalog.isTempView().
Why are the changes needed?
To improve code maintenance. Currently, there are two methods that do the same but have different names:
def isTempView(nameParts: Seq[String]): Boolean

and
def isTemporaryTable(name: TableIdentifier): Boolean

Does this PR introduce any user-facing change?
Should not since SessionCatalog is not public API.
How was this patch tested?
By running the existing tests:
$ build/sbt -Phive-2.3 -Phive-thriftserver "test:testOnly *SessionCatalogSuite"

Test build #134376 has started for PR 31295 at commit 8e33c19.

Test build #134376 has started for PR 31295 at commit 8e33c19.

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/38963/

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/38963/

@dongjoon-hyun @cloud-fan Could you review this PR, please.

@dongjoon-hyun @cloud-fan Could you review this PR, please.

Kubernetes integration test status success
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/38963/

Kubernetes integration test status success
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/38963/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/38963/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/38963/

Test build #134376 has finished for PR 31295 at commit 8e33c19.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Test build #134376 has finished for PR 31295 at commit 8e33c19.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/134376/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/134376/

@dongjoon-hyun I added an JIRA id to the PR title.

@dongjoon-hyun I added an JIRA id to the PR title.

Merged to master.
cc @cloud-fan

Merged to master.
cc @cloud-fan


vk.com failed with error 0

Error message: Call to a member function getAttribute() on null
Query string: action=display&bridge=Vk&u=advance_empire&format=Html
Version: dev.2022-06-14

@em92

Cannot reproduce it. https://feed.eugenemolotov.ru/?action=display&bridge=Vk&u=advance_empire&format=Html

Pretty sure, that it is related to fixed issue. https://github.com/RSS-Bridge/rss-bridge/pull/3244/files

still problem?


rust-cbindgen: 0.24.2 -> 0.24.3

Description of changes
https://github.com/eqrion/cbindgen/releases/tag/v0.24.3
Waiting for firefox to build.

Things done

Built on platform(s)

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

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

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

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

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

[x] Fits CONTRIBUTING.md.

Firefox build-tested on aarch64-linux and x86_64-linux.


Adding user to project not reflected until reload

When adding a user to a project from the user page, you need to reload to see the result. Unlike with the API key generation which is immediately reflected.

This was fix in a previous PR. I can't remember which one.