Magento 2 Label translation showing braces - curly-braces

Labels showing multiple translations between double curly-braces.
I have this problem both on the front and backend of Magento 2.
This is what I've tried so far:
Cleared and flushed the cache
re-deployed static content
Updated Magento 2.2.5 to 2.2.6
Please look at the pictures for more info
Magento 2 Frontend
Magento 2 Backend
Any ideas?
Solution
It's not a pretty fix but I've restored both js-translation.json files at the static frontend and backup folder.

I had the same issue, this issue comes when you did not properly disable the configuration or inline translation configuration.
please check the inline translation or any other configuration and make sure you disable the configuration properly which applies to specific mode(developer) and before updating.
After that please run the following commands
$rm -rf var/cache/* var/view_processed/* generated/code/*
$php bin/magento setup:upgrade
$php bin/magento setup:static-content:deploy
$php bin/magento setup:di:compile
$php bin/magento cache:clean
$chmod 777 -R app/ var/ generated/ pub/

Are you sure you have all php dependencies installed correctly?
Solution was suggested on this stackexchange thread: https://magento.stackexchange.com/questions/245516/why-are-the-admin-labels-showing-curly-braces

I had the same issue several times, and don't know why its happening, but this solved my problem:
Manually delete generated/metadata, generated/code, var/cache, var/page_cache, pub/static (be careful not to delete htaccess files),
then run setup:upgrade, setup:static-content:deploy and cache:clean.
Hope it helps.

Related

$config must be a string or an array

I am having errors when trying to access the subscription section on my app . It's something with the stripe API, this error occurs mostly when server caches are being cleared. I checked to clear caches, check config.app.php, payment controller, and all of that but not really understanding the source of this error!
Therefore I need someone's help, maybe someone who had this issue before here is the code line for that on vendor/stripe/stripe-php/lib/BaseStripeClient.php. please suggest a solution for this error! I will be grateful
if (\is_string($config)) {
$config = ['api_key' => $config];
} elseif (!\is_array($config)) {
throw new \Stripe\Exception\InvalidArgumentException('$config must be a string or an array');
}
make sure you have STRIPE_SECRET and STRIPE_KEY in your .env file
then you can just go with php artisan config:cache
if you have these in you .env file and error persists try removing the the files in bootstrap/cache i.e. rm -rf bootsrap/cache/*
php artisan config:cache run this command
Your application is pulling a cached version of its config. Delete the bootstrap/cache/config.php file and refresh your browser and the error should go away.
I haven't had much luck with running php artisan cache:clear so I just remove the file manually or run the command below.
If you run the terminal command rm -rf bootstrap/cache/* in the root of the application it should remove all the files in the cache directory.

Disabling directory listing in Zeppelin

Has anyone disabled directory listing in Zeppelin 0.6.0 (or other version) as a part of security measures?
Could you please let me know about the same.
Following "How to disable directory listing for Jetty's WebAppContext?", I've looked up the Apache Zeppelin installation directory, identified the web.xml file and added
<param-name>dirAllowed</param-name>
<param-value>false</param-value>
After restart it looked like that the configuration parameter wasn't picked up. Directory listing was still possible.
For my understanding, according ZEPPELIN-2014 and a commit, a patch of ZeppelinServer.java would be required to make such configuration possible or active.
It will be fixed as of Zeppelin 0.7.3 or 0.8.0.

ATK Examples directing to a different DSN

Just installed atk4 (latest) on my webserver.
The default page loads fine, the DB test shows success, but the examples included in the package seem to be referencing a dsn other than what is in the config. Despite my (working) config info the examples try to connect to root#localhost and fail. That's not my dsn info from config.
I checked the agiletoolkit site and their example.agiletookit page is doing the same thing.
Is this a bug or are there multiple configs?
If you have installed using the new secure install
curl -sS http://agiletoolkit.org/install | sh
Then there was a problem with the bootstrapped repository. Here is fix:
https://github.com/atk4/atk4-secure/commit/a0c282e35277a044ed9048b7c292ac8da1b3092a

CakePHP 2.0 - Cake was unable to write to File cache

I'm using CakePHP 2.0 RC-1. After checking out the project from SVN, the application is starting to complain that it can't write cache files to the tmp/cache directory. Since this is local, I know the directory is writeable and I can CLEARLY see that the directories are even filled with files, so the error is a bit strange.
Here are some of the errors I've encountered:
_cake_core_ cache was unable to write 'cake_dev_nb' to File cache
fopen(c:\cake\app\tmp\cache\models\cake_model_default_media) [function.fopen]: failed to open stream: No error [CORE\Cake\Cache\Engine\FileEngine.php, line 127]
No error?! Wth?
Now, if I look in the FileEngine file, at line 127 it reads:
if (!$handle = fopen($this->_File->getPathName(), 'c')) {
return false;
}
By replacing the "c" with "w", no error is encountered and everything works as it should. But, it should not be necessary to modify the core Cake libraries to work around this problem. Let me repeat that on my other computer this works as intended, without editing the core library. Both use the Windows OS and the read/write rights to the tmp/cache-folder is exactly the same.
Edit: Here's a site that experiences the error outputs I'm having locally
Example site found by Googling. Not my site: http://www.12h30.net/credit/
Any suggestions?
Update: Here is why: This is caused if you have a PHP-version that's too low, before 5.2.6, as outlined by "api55" in the comments. Thanks for the reply. Hope this helps you too.
Well, in my case, when I checked my app, it hadn't the /tmp folder. Then I created the structure (/tmp/cache/models, /tmp/cache/persistent) and all worked well. This happened to me maybe git ignore empty folders, so they weren't created.
I had a similar problem, it was because I had chown -R www to the app/tmp directory to get Cake to run "properly" without giving everyone write privileges. Looks like during development the only way to use the console and the web is to give everyone write privileges, or add yourself to the www group perhaps.
Easy solution:
chmod -R 777 app/tmp
or
chown -R username app/tmp
while using the console and
chown -R www app/tmp
when using the web
Just give the right CHMOD (776 works fine for me) to app/tmp
for windows users with the same error/warning: make sure you run the command prompt in elevated mode ;)

Ushahidi No Input File Specified

I have been trying to install Ushahidi platform for weeks but without any luck. I recently started over using Ushahidi latest release ushahidi-Ushahidi_Web-2.0.1-140-g0991172.zip and extracted it to folder ushahidi under my root.
I am using godaddy Linux server. I have tried both the manual and wizard to setup Ushahidi. In all cases, after installation, I get the same error when I try to access admin page. The error reads:
No input file specified.
I have tried tried installing using the wizard and the manual process. My PHP version is as required.
Any help will be appreciated. I need it to work so I can move on and customize it. Very disappointing such a good open source tool has poor installation guides!
Thanks.
Sting
there are a few things that can trip up following the installation.
Make sure that:
mod_rewrite is turned on in apache "a2enmod rewrite"
AllowOverride All is set in your apache config for your site (/etc/apache2/sites-available/default)
your .htaccess file points to the correct webroot

Resources