Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The merged asset : couldn't be parsed for getting the hashcode #1493

Closed
anonymous-matomo-user opened this issue Jul 21, 2010 · 4 comments
Closed
Labels
Bug For errors / faults / flaws / inconsistencies etc. Critical Indicates the severity of an issue is very critical and the issue has a very high priority.
Milestone

Comments

@anonymous-matomo-user
Copy link

Heya!

After upgrading to 0.6.4 both of my installations have died:

The merged asset : couldn't be parsed for getting the hashcode.
Backtrace:
#0 /dir/core/AssetManager.php(386): Piwik_AssetManager::getMergedAssetHash('css')
#1 /dir/core/AssetManager.php(433): Piwik_AssetManager::removeMergedAsset('css')
#2 /dir/plugins/CoreUpdater/CoreUpdater.php(64): Piwik_AssetManager::removeMergedAssets()
#3 function: Piwik_CoreUpdater->dispatch(Object(Piwik_Event_Notification))
#4 /dir/libs/Event/Dispatcher.php(284): call_user_func_array(Array, Array)
#5 /dir/core/PluginsManager.php(532): Event_Dispatcher->postNotification(Object(Piwik_Event_Notification), true, false)
#6 /dir/core/FrontController.php(227): Piwik_PostEvent('FrontController...')
#7 /dir/index.php(58): Piwik_FrontController->init()
#8 {main}

@mattab
Copy link
Member

mattab commented Jul 21, 2010

Please apply the following patch to your Piwik:

Index: /trunk/core/AssetManager.php
===================================================================
--- /trunk/core/AssetManager.php (revision 2619)
+++ /trunk/core/AssetManager.php (revision 2620)
@@ -325,38 +325,40 @@
     *
     * @throws Exception if there is more than one file of the same type.
     * @return string The hashcode of the merged file, false if not present.
     */
    private static function getMergedAssetHash ($type)
    {   
        $mergedFileDirectory = self::getMergedFileDirectory();

        $matchingFiles = glob( $mergedFileDirectory . "*." . $type );

+       if($matchingFiles === false)
+       {
+           return false;
+       }

(3 lines to add)
does it fix it for you?

@anonymous-matomo-user
Copy link
Author

It works for me.
Thank you very much :)

@robocoder
Copy link
Contributor

Fixed in [(which also reverts an earlier fix in 2619).

@anonymous-matomo-user
Copy link
Author

Jep works for me as well, thanks!

@anonymous-matomo-user anonymous-matomo-user added this to the Piwik 0.6.5 milestone Jul 8, 2014
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc. Critical Indicates the severity of an issue is very critical and the issue has a very high priority.
Projects
None yet
Development

No branches or pull requests

3 participants