I'm not sure what the bear activity is like along the JMT this year, but some bear stories from years past:
Something else the [Yosemite] rangers told us at the bear talk - they don't (or no longer) relocate trouble bears. They'll just mosey back to where the easy pickings are. They get shot.
On one day we saw a baby bear foraging through a nearby meadow. Sadly, the baby was oblivious to the crowd that formed to watch it. We heard from a [Yosemite] ranger later that some tourists had been feeding a bear in that area. Also heard that a lot (20?) bears had to be killed last year because they're too familiar with humans

My favorite quote when researching my hike was from an unnamed Yosemite Ranger:
"Our main problem with bears is that the upper end of the intelligence scale of the Yosemite bears is higher than the lower end of the intelligence scale of the Yosemite tourists."
I will be carrying a bear can to store my food in through the Sierras. I’ve had one incident where a bear came after my pack one pitch-black night. The pack had no food in it, but did contain a plastic bag that had at one point held another plastic bag that had food in it. (The bag in the pack had never come in direct contact with the food, it was the outer bag of a double bagged meal). It was clear the bear was after THAT plastic bag. I learned my lesson that night. EVERYTHING that even REMOTELY is scented or food-like goes in the bear can.
I had a resupply at Muir Trail Ranch, and ended up able to fit all of my food (about 9 days worth) into the canister.
I didn’t have any experiences with bears, but I did hear a lot of stories.
From another JMT hiker: “I was camped at 1000 Island Lake, and I was asleep in my tent. At about midnight, I heard all kinds of yelling and pot-banging and commotion at the other end of the lake. Then it was quiet. A few minutes later, there was commotion a little bit closer. This continued as the bear traveled to each of the campsites along the lake, looking for food. The bear eventually made it to my campsite, and I yelled and chased it away.”
From a ranger at a campsite halfway up Forester Pass: “Last year there was someone camped right here, and they stored their food improperly (turns out “improperly” meant “in a bag, on the ground, a few feet from the tent door”). The bear came and started to make off with the food, and the camper opened the tent door. The bear then swiped the camper across the face.”
My encounters with bears in Yosemite all happened at night, and especially at or nearby a heavy use area. Those west coast critters are clever and know exactly how to obtain food. The ranger advice was for me and my buddy to pile pine cones next to us and throw them at a bear if it approached whilst banging cooking pots etc. We were "bluff charged" by one bear but had no time what so ever to grab any cones. They know that they can't open those bear canniters themselves so they just watch and wait for you to open it for them, then they charge at you to scare the crap out of you, you then drop the said cannister and the bear feasts.
...you should definitely be aware of the black bears around Yosemite and Sequoia/Kings Canyon. They do not run away from hikers and love to hang out around the bear boxes. Yelling and even throwing rocks seems to have very little effect on the bears around the Rae Lakes area.
A few years back while heading out into the Sierra from Sequoia/Kings we had to camp rather early on the trail due to a late start. We didnt know it but we were just above 2 car campgrounds. As the night grew later we relaized where we were but not much we could do about it. The boom boxes and loud banter continued until well after hiker midnight. We fially dozed off about 10:30. Around 1AM all hell broke loose down there as the bears made their nightly prowl through. People banging pots and yelling at the bears. A few rubber bullet shots later by the rangers and all was quiet again. Back to sleep only to be awakened by a loud snorting sound outside the tent. OK our turn. 2 bears searching for our food (safely hidden away in canistars) So we got up to chase them off and by the time we got outside 2 more. not good. so we start to yell at them, throw rocks, bang hikimg poles togather etc and before we know it another shows up.....and then another....this isnt looking good. I picked up a piece of fire wood and threw it at the closest bear and it hit a bolder and snaped in half. I dont know if it was the sound or what but all the bears turned and ran back the way they had come. the funny part is an hour later all hell broke loose in the campgroung again!
Backcountry bears want nothing to do with you - but will capitalize on any "life is harder when you're stupid" food mishandling episodes. I've never used a bear container - but will use bear boxes if available, sleep with my food, but most importantly, stealth/dry camp (I hike solo). I carry bear spray, keep pot and cup available as noise makers in the tent, have treking poles available to joust with Smokey (admittedly, probably as something to do to keep busy as the critter destroys my tent), and ample sized rocks near the tent entrance to keep his attention if he backs off.