2.1 (ReflectionException): Class … does not exist












2















I wrote a custom shipping module for Magento 2.0 that adds an LTL/Fright option. It worked in Magento 2.0.7, and I was recently testing 2.1.7. It appears all of my other (self authored) modules work, but my Shipping module does not.



After adding an item to the cart, and going to http://localhost/checkout/cart I get the following error:



Exception #0 (ReflectionException): Class ComstarTliModelCarrier does not exist
#0 D:WebhtmlvendormagentoframeworkCodeReaderClassReader.php(19): ReflectionClass->__construct('Comstar\Tli\Mod...')
#1 D:WebhtmlvendormagentoframeworkObjectManagerDefinitionRuntime.php(44): MagentoFrameworkCodeReaderClassReader->getConstructor('Comstar\Tli\Mod...')
#2 D:WebhtmlvendormagentoframeworkObjectManagerFactoryDynamicDeveloper.php(71): MagentoFrameworkObjectManagerDefinitionRuntime->getParameters('Comstar\Tli\Mod...')
#3 D:WebhtmlvendormagentoframeworkObjectManagerObjectManager.php(57): MagentoFrameworkObjectManagerFactoryDynamicDeveloper->create('Comstar\Tli\Mod...', Array)
#4 D:Webhtmlvendormagentomodule-shippingModelCarrierFactory.php(74): MagentoFrameworkObjectManagerObjectManager->create('Comstar\Tli\Mod...')
#5 D:Webhtmlvendormagentomodule-shippingModelConfig.php(65): MagentoShippingModelCarrierFactory->create('tli', NULL)
#6 D:Webhtmlvendormagentomodule-checkoutModelDefaultConfigProvider.php(590): MagentoShippingModelConfig->getActiveCarriers()
#7 D:Webhtmlvendormagentomodule-checkoutModelDefaultConfigProvider.php(292): MagentoCheckoutModelDefaultConfigProvider->getActiveCarriers()
#8 D:WebhtmlvendormagentoframeworkInterceptionInterceptor.php(146): MagentoCheckoutModelDefaultConfigProvider->getConfig()
#9 D:WebhtmlvargenerationMagentoCheckoutModelDefaultConfigProviderInterceptor.php(26): MagentoCheckoutModelDefaultConfigProviderInterceptor->___callPlugins('getConfig', Array, Array)
#10 D:Webhtmlvendormagentomodule-checkoutModelCompositeConfigProvider.php(32): MagentoCheckoutModelDefaultConfigProviderInterceptor->getConfig()
#11 D:Webhtmlvendormagentomodule-checkoutBlockCartShipping.php(54): MagentoCheckoutModelCompositeConfigProvider->getConfig()
#12 D:Webhtmlvendormagentomodule-checkoutviewfrontendtemplatescartshipping.phtml(28): MagentoCheckoutBlockCartShipping->getCheckoutConfig()
.... (stack trace continues to 95 lines)


app/code/Comstar/Tli/Model/Carrier.php



namespace ComstarTliModel;

[... class imports ...]

class Carrier extends AbstractCarrier implements CarrierInterface
{
[... var declarations ...]

public function __construct([... DI ...])
{
parent::__construct($scopeConfig, $errorFactory, $log, $data)
}
}


app/code/Comstar/Tli/etc/config.xml



<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Store:etc/config.xsd">
<default>
<carriers>
<tli>
<active>1</active>
<sallowspecific>0</sallowspecific>
<allowed_methods>AACR,AACT</allowed_methods>
<model>ComstarTliModelCarrier</model>
<type>LTL</type>
<title>Freight</title>
<name>Comstar LTL</name>
<specificerrmsg>There are no LTL Quotes available for this shipment.</specificerrmsg>
<min_package_weight>125</min_package_weight>
<max_package_weight>10000</max_package_weight>
</tli>
</carriers>
</default>
</config>


The Class ComstarTliModelCarrier clearly exists, and as I said, this module worked in 2.0.7. I did a quick review of Magento_Ups to see if anything major changed in the way shipping modules are loaded, but it doesn't appear to be built any differently.



I am running on WAMP 3.0.9, PHP 7.0.21. I updated from 2.0.7 to 2.1.7 by deleting the /vendor/ folder and copying all 2.1.7 files into the Magento 2 root.



Why isn't Magento 2.1 able to find my Class?










share|improve this question





























    2















    I wrote a custom shipping module for Magento 2.0 that adds an LTL/Fright option. It worked in Magento 2.0.7, and I was recently testing 2.1.7. It appears all of my other (self authored) modules work, but my Shipping module does not.



    After adding an item to the cart, and going to http://localhost/checkout/cart I get the following error:



    Exception #0 (ReflectionException): Class ComstarTliModelCarrier does not exist
    #0 D:WebhtmlvendormagentoframeworkCodeReaderClassReader.php(19): ReflectionClass->__construct('Comstar\Tli\Mod...')
    #1 D:WebhtmlvendormagentoframeworkObjectManagerDefinitionRuntime.php(44): MagentoFrameworkCodeReaderClassReader->getConstructor('Comstar\Tli\Mod...')
    #2 D:WebhtmlvendormagentoframeworkObjectManagerFactoryDynamicDeveloper.php(71): MagentoFrameworkObjectManagerDefinitionRuntime->getParameters('Comstar\Tli\Mod...')
    #3 D:WebhtmlvendormagentoframeworkObjectManagerObjectManager.php(57): MagentoFrameworkObjectManagerFactoryDynamicDeveloper->create('Comstar\Tli\Mod...', Array)
    #4 D:Webhtmlvendormagentomodule-shippingModelCarrierFactory.php(74): MagentoFrameworkObjectManagerObjectManager->create('Comstar\Tli\Mod...')
    #5 D:Webhtmlvendormagentomodule-shippingModelConfig.php(65): MagentoShippingModelCarrierFactory->create('tli', NULL)
    #6 D:Webhtmlvendormagentomodule-checkoutModelDefaultConfigProvider.php(590): MagentoShippingModelConfig->getActiveCarriers()
    #7 D:Webhtmlvendormagentomodule-checkoutModelDefaultConfigProvider.php(292): MagentoCheckoutModelDefaultConfigProvider->getActiveCarriers()
    #8 D:WebhtmlvendormagentoframeworkInterceptionInterceptor.php(146): MagentoCheckoutModelDefaultConfigProvider->getConfig()
    #9 D:WebhtmlvargenerationMagentoCheckoutModelDefaultConfigProviderInterceptor.php(26): MagentoCheckoutModelDefaultConfigProviderInterceptor->___callPlugins('getConfig', Array, Array)
    #10 D:Webhtmlvendormagentomodule-checkoutModelCompositeConfigProvider.php(32): MagentoCheckoutModelDefaultConfigProviderInterceptor->getConfig()
    #11 D:Webhtmlvendormagentomodule-checkoutBlockCartShipping.php(54): MagentoCheckoutModelCompositeConfigProvider->getConfig()
    #12 D:Webhtmlvendormagentomodule-checkoutviewfrontendtemplatescartshipping.phtml(28): MagentoCheckoutBlockCartShipping->getCheckoutConfig()
    .... (stack trace continues to 95 lines)


    app/code/Comstar/Tli/Model/Carrier.php



    namespace ComstarTliModel;

    [... class imports ...]

    class Carrier extends AbstractCarrier implements CarrierInterface
    {
    [... var declarations ...]

    public function __construct([... DI ...])
    {
    parent::__construct($scopeConfig, $errorFactory, $log, $data)
    }
    }


    app/code/Comstar/Tli/etc/config.xml



    <?xml version="1.0"?>
    <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Store:etc/config.xsd">
    <default>
    <carriers>
    <tli>
    <active>1</active>
    <sallowspecific>0</sallowspecific>
    <allowed_methods>AACR,AACT</allowed_methods>
    <model>ComstarTliModelCarrier</model>
    <type>LTL</type>
    <title>Freight</title>
    <name>Comstar LTL</name>
    <specificerrmsg>There are no LTL Quotes available for this shipment.</specificerrmsg>
    <min_package_weight>125</min_package_weight>
    <max_package_weight>10000</max_package_weight>
    </tli>
    </carriers>
    </default>
    </config>


    The Class ComstarTliModelCarrier clearly exists, and as I said, this module worked in 2.0.7. I did a quick review of Magento_Ups to see if anything major changed in the way shipping modules are loaded, but it doesn't appear to be built any differently.



    I am running on WAMP 3.0.9, PHP 7.0.21. I updated from 2.0.7 to 2.1.7 by deleting the /vendor/ folder and copying all 2.1.7 files into the Magento 2 root.



    Why isn't Magento 2.1 able to find my Class?










    share|improve this question



























      2












      2








      2








      I wrote a custom shipping module for Magento 2.0 that adds an LTL/Fright option. It worked in Magento 2.0.7, and I was recently testing 2.1.7. It appears all of my other (self authored) modules work, but my Shipping module does not.



      After adding an item to the cart, and going to http://localhost/checkout/cart I get the following error:



      Exception #0 (ReflectionException): Class ComstarTliModelCarrier does not exist
      #0 D:WebhtmlvendormagentoframeworkCodeReaderClassReader.php(19): ReflectionClass->__construct('Comstar\Tli\Mod...')
      #1 D:WebhtmlvendormagentoframeworkObjectManagerDefinitionRuntime.php(44): MagentoFrameworkCodeReaderClassReader->getConstructor('Comstar\Tli\Mod...')
      #2 D:WebhtmlvendormagentoframeworkObjectManagerFactoryDynamicDeveloper.php(71): MagentoFrameworkObjectManagerDefinitionRuntime->getParameters('Comstar\Tli\Mod...')
      #3 D:WebhtmlvendormagentoframeworkObjectManagerObjectManager.php(57): MagentoFrameworkObjectManagerFactoryDynamicDeveloper->create('Comstar\Tli\Mod...', Array)
      #4 D:Webhtmlvendormagentomodule-shippingModelCarrierFactory.php(74): MagentoFrameworkObjectManagerObjectManager->create('Comstar\Tli\Mod...')
      #5 D:Webhtmlvendormagentomodule-shippingModelConfig.php(65): MagentoShippingModelCarrierFactory->create('tli', NULL)
      #6 D:Webhtmlvendormagentomodule-checkoutModelDefaultConfigProvider.php(590): MagentoShippingModelConfig->getActiveCarriers()
      #7 D:Webhtmlvendormagentomodule-checkoutModelDefaultConfigProvider.php(292): MagentoCheckoutModelDefaultConfigProvider->getActiveCarriers()
      #8 D:WebhtmlvendormagentoframeworkInterceptionInterceptor.php(146): MagentoCheckoutModelDefaultConfigProvider->getConfig()
      #9 D:WebhtmlvargenerationMagentoCheckoutModelDefaultConfigProviderInterceptor.php(26): MagentoCheckoutModelDefaultConfigProviderInterceptor->___callPlugins('getConfig', Array, Array)
      #10 D:Webhtmlvendormagentomodule-checkoutModelCompositeConfigProvider.php(32): MagentoCheckoutModelDefaultConfigProviderInterceptor->getConfig()
      #11 D:Webhtmlvendormagentomodule-checkoutBlockCartShipping.php(54): MagentoCheckoutModelCompositeConfigProvider->getConfig()
      #12 D:Webhtmlvendormagentomodule-checkoutviewfrontendtemplatescartshipping.phtml(28): MagentoCheckoutBlockCartShipping->getCheckoutConfig()
      .... (stack trace continues to 95 lines)


      app/code/Comstar/Tli/Model/Carrier.php



      namespace ComstarTliModel;

      [... class imports ...]

      class Carrier extends AbstractCarrier implements CarrierInterface
      {
      [... var declarations ...]

      public function __construct([... DI ...])
      {
      parent::__construct($scopeConfig, $errorFactory, $log, $data)
      }
      }


      app/code/Comstar/Tli/etc/config.xml



      <?xml version="1.0"?>
      <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Store:etc/config.xsd">
      <default>
      <carriers>
      <tli>
      <active>1</active>
      <sallowspecific>0</sallowspecific>
      <allowed_methods>AACR,AACT</allowed_methods>
      <model>ComstarTliModelCarrier</model>
      <type>LTL</type>
      <title>Freight</title>
      <name>Comstar LTL</name>
      <specificerrmsg>There are no LTL Quotes available for this shipment.</specificerrmsg>
      <min_package_weight>125</min_package_weight>
      <max_package_weight>10000</max_package_weight>
      </tli>
      </carriers>
      </default>
      </config>


      The Class ComstarTliModelCarrier clearly exists, and as I said, this module worked in 2.0.7. I did a quick review of Magento_Ups to see if anything major changed in the way shipping modules are loaded, but it doesn't appear to be built any differently.



      I am running on WAMP 3.0.9, PHP 7.0.21. I updated from 2.0.7 to 2.1.7 by deleting the /vendor/ folder and copying all 2.1.7 files into the Magento 2 root.



      Why isn't Magento 2.1 able to find my Class?










      share|improve this question
















      I wrote a custom shipping module for Magento 2.0 that adds an LTL/Fright option. It worked in Magento 2.0.7, and I was recently testing 2.1.7. It appears all of my other (self authored) modules work, but my Shipping module does not.



      After adding an item to the cart, and going to http://localhost/checkout/cart I get the following error:



      Exception #0 (ReflectionException): Class ComstarTliModelCarrier does not exist
      #0 D:WebhtmlvendormagentoframeworkCodeReaderClassReader.php(19): ReflectionClass->__construct('Comstar\Tli\Mod...')
      #1 D:WebhtmlvendormagentoframeworkObjectManagerDefinitionRuntime.php(44): MagentoFrameworkCodeReaderClassReader->getConstructor('Comstar\Tli\Mod...')
      #2 D:WebhtmlvendormagentoframeworkObjectManagerFactoryDynamicDeveloper.php(71): MagentoFrameworkObjectManagerDefinitionRuntime->getParameters('Comstar\Tli\Mod...')
      #3 D:WebhtmlvendormagentoframeworkObjectManagerObjectManager.php(57): MagentoFrameworkObjectManagerFactoryDynamicDeveloper->create('Comstar\Tli\Mod...', Array)
      #4 D:Webhtmlvendormagentomodule-shippingModelCarrierFactory.php(74): MagentoFrameworkObjectManagerObjectManager->create('Comstar\Tli\Mod...')
      #5 D:Webhtmlvendormagentomodule-shippingModelConfig.php(65): MagentoShippingModelCarrierFactory->create('tli', NULL)
      #6 D:Webhtmlvendormagentomodule-checkoutModelDefaultConfigProvider.php(590): MagentoShippingModelConfig->getActiveCarriers()
      #7 D:Webhtmlvendormagentomodule-checkoutModelDefaultConfigProvider.php(292): MagentoCheckoutModelDefaultConfigProvider->getActiveCarriers()
      #8 D:WebhtmlvendormagentoframeworkInterceptionInterceptor.php(146): MagentoCheckoutModelDefaultConfigProvider->getConfig()
      #9 D:WebhtmlvargenerationMagentoCheckoutModelDefaultConfigProviderInterceptor.php(26): MagentoCheckoutModelDefaultConfigProviderInterceptor->___callPlugins('getConfig', Array, Array)
      #10 D:Webhtmlvendormagentomodule-checkoutModelCompositeConfigProvider.php(32): MagentoCheckoutModelDefaultConfigProviderInterceptor->getConfig()
      #11 D:Webhtmlvendormagentomodule-checkoutBlockCartShipping.php(54): MagentoCheckoutModelCompositeConfigProvider->getConfig()
      #12 D:Webhtmlvendormagentomodule-checkoutviewfrontendtemplatescartshipping.phtml(28): MagentoCheckoutBlockCartShipping->getCheckoutConfig()
      .... (stack trace continues to 95 lines)


      app/code/Comstar/Tli/Model/Carrier.php



      namespace ComstarTliModel;

      [... class imports ...]

      class Carrier extends AbstractCarrier implements CarrierInterface
      {
      [... var declarations ...]

      public function __construct([... DI ...])
      {
      parent::__construct($scopeConfig, $errorFactory, $log, $data)
      }
      }


      app/code/Comstar/Tli/etc/config.xml



      <?xml version="1.0"?>
      <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Store:etc/config.xsd">
      <default>
      <carriers>
      <tli>
      <active>1</active>
      <sallowspecific>0</sallowspecific>
      <allowed_methods>AACR,AACT</allowed_methods>
      <model>ComstarTliModelCarrier</model>
      <type>LTL</type>
      <title>Freight</title>
      <name>Comstar LTL</name>
      <specificerrmsg>There are no LTL Quotes available for this shipment.</specificerrmsg>
      <min_package_weight>125</min_package_weight>
      <max_package_weight>10000</max_package_weight>
      </tli>
      </carriers>
      </default>
      </config>


      The Class ComstarTliModelCarrier clearly exists, and as I said, this module worked in 2.0.7. I did a quick review of Magento_Ups to see if anything major changed in the way shipping modules are loaded, but it doesn't appear to be built any differently.



      I am running on WAMP 3.0.9, PHP 7.0.21. I updated from 2.0.7 to 2.1.7 by deleting the /vendor/ folder and copying all 2.1.7 files into the Magento 2 root.



      Why isn't Magento 2.1 able to find my Class?







      magento-2.1 shipping






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Apr 2 '18 at 10:52









      Teja Bhagavan Kollepara

      2,94841847




      2,94841847










      asked Jul 21 '17 at 14:00









      andyjvandyjv

      1,98211740




      1,98211740






















          4 Answers
          4






          active

          oldest

          votes


















          3














          I my case,



          enter image description here



          I had actually a syntax error in the constructor. but it was not shown as usual errors with line number.
          I ran,



          php bin/magento setup:di:compile


          It displayed there is syntax error and showed line number.
          Then updgrade,



          php bin/magento setup:upgrade


          and deploy,



          php bin/magento setup:static-content deploy


          May be helpful.






          share|improve this answer



















          • 1





            Yes, setup:di:compile is the key. Thanks!

            – hayatbiralem
            Sep 28 '18 at 8:49





















          1














          Turns out on this particular file, I had opened with a <? tag instead of a <?php tag. I'm not sure if it was the newer version of WAMP or PHP that triggered that sensitivity, but using <?php fixed the problem!






          share|improve this answer
























          • old post but - worth noting php.ini setting allow_short_open_tags (or something similar) - setting that to yes allows use of <?

            – treyBake
            Nov 8 '17 at 14:22



















          0














          You can try to use



          setup:di:compile


          command.



          Also, try to remove var/cache/* var/page_cache/* var/generation/*



          and run



          setup:upgrade


          command.






          share|improve this answer
























          • I'm in developer mode with the cache disabled. I ran setup:di:compile anyway, and it only moves the error to the PHP log and changes the stack trace a little.

            – andyjv
            Jul 21 '17 at 15:38



















          0














          Below command works for me
          In order to bypass "Allowed memory size of error" add memory_limit=-1 before the command.




          php -d memory_limit=-1 bin/magento setup:di:compile





          share|improve this answer








          New contributor




          gurcharan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
          Check out our Code of Conduct.




















            Your Answer








            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "479"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: false,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: null,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














            draft saved

            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f184900%2f2-1-reflectionexception-class-does-not-exist%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            4 Answers
            4






            active

            oldest

            votes








            4 Answers
            4






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            3














            I my case,



            enter image description here



            I had actually a syntax error in the constructor. but it was not shown as usual errors with line number.
            I ran,



            php bin/magento setup:di:compile


            It displayed there is syntax error and showed line number.
            Then updgrade,



            php bin/magento setup:upgrade


            and deploy,



            php bin/magento setup:static-content deploy


            May be helpful.






            share|improve this answer



















            • 1





              Yes, setup:di:compile is the key. Thanks!

              – hayatbiralem
              Sep 28 '18 at 8:49


















            3














            I my case,



            enter image description here



            I had actually a syntax error in the constructor. but it was not shown as usual errors with line number.
            I ran,



            php bin/magento setup:di:compile


            It displayed there is syntax error and showed line number.
            Then updgrade,



            php bin/magento setup:upgrade


            and deploy,



            php bin/magento setup:static-content deploy


            May be helpful.






            share|improve this answer



















            • 1





              Yes, setup:di:compile is the key. Thanks!

              – hayatbiralem
              Sep 28 '18 at 8:49
















            3












            3








            3







            I my case,



            enter image description here



            I had actually a syntax error in the constructor. but it was not shown as usual errors with line number.
            I ran,



            php bin/magento setup:di:compile


            It displayed there is syntax error and showed line number.
            Then updgrade,



            php bin/magento setup:upgrade


            and deploy,



            php bin/magento setup:static-content deploy


            May be helpful.






            share|improve this answer













            I my case,



            enter image description here



            I had actually a syntax error in the constructor. but it was not shown as usual errors with line number.
            I ran,



            php bin/magento setup:di:compile


            It displayed there is syntax error and showed line number.
            Then updgrade,



            php bin/magento setup:upgrade


            and deploy,



            php bin/magento setup:static-content deploy


            May be helpful.







            share|improve this answer












            share|improve this answer



            share|improve this answer










            answered Aug 9 '18 at 22:24









            Ajwad TaqviAjwad Taqvi

            32415




            32415








            • 1





              Yes, setup:di:compile is the key. Thanks!

              – hayatbiralem
              Sep 28 '18 at 8:49
















            • 1





              Yes, setup:di:compile is the key. Thanks!

              – hayatbiralem
              Sep 28 '18 at 8:49










            1




            1





            Yes, setup:di:compile is the key. Thanks!

            – hayatbiralem
            Sep 28 '18 at 8:49







            Yes, setup:di:compile is the key. Thanks!

            – hayatbiralem
            Sep 28 '18 at 8:49















            1














            Turns out on this particular file, I had opened with a <? tag instead of a <?php tag. I'm not sure if it was the newer version of WAMP or PHP that triggered that sensitivity, but using <?php fixed the problem!






            share|improve this answer
























            • old post but - worth noting php.ini setting allow_short_open_tags (or something similar) - setting that to yes allows use of <?

              – treyBake
              Nov 8 '17 at 14:22
















            1














            Turns out on this particular file, I had opened with a <? tag instead of a <?php tag. I'm not sure if it was the newer version of WAMP or PHP that triggered that sensitivity, but using <?php fixed the problem!






            share|improve this answer
























            • old post but - worth noting php.ini setting allow_short_open_tags (or something similar) - setting that to yes allows use of <?

              – treyBake
              Nov 8 '17 at 14:22














            1












            1








            1







            Turns out on this particular file, I had opened with a <? tag instead of a <?php tag. I'm not sure if it was the newer version of WAMP or PHP that triggered that sensitivity, but using <?php fixed the problem!






            share|improve this answer













            Turns out on this particular file, I had opened with a <? tag instead of a <?php tag. I'm not sure if it was the newer version of WAMP or PHP that triggered that sensitivity, but using <?php fixed the problem!







            share|improve this answer












            share|improve this answer



            share|improve this answer










            answered Jul 21 '17 at 19:28









            andyjvandyjv

            1,98211740




            1,98211740













            • old post but - worth noting php.ini setting allow_short_open_tags (or something similar) - setting that to yes allows use of <?

              – treyBake
              Nov 8 '17 at 14:22



















            • old post but - worth noting php.ini setting allow_short_open_tags (or something similar) - setting that to yes allows use of <?

              – treyBake
              Nov 8 '17 at 14:22

















            old post but - worth noting php.ini setting allow_short_open_tags (or something similar) - setting that to yes allows use of <?

            – treyBake
            Nov 8 '17 at 14:22





            old post but - worth noting php.ini setting allow_short_open_tags (or something similar) - setting that to yes allows use of <?

            – treyBake
            Nov 8 '17 at 14:22











            0














            You can try to use



            setup:di:compile


            command.



            Also, try to remove var/cache/* var/page_cache/* var/generation/*



            and run



            setup:upgrade


            command.






            share|improve this answer
























            • I'm in developer mode with the cache disabled. I ran setup:di:compile anyway, and it only moves the error to the PHP log and changes the stack trace a little.

              – andyjv
              Jul 21 '17 at 15:38
















            0














            You can try to use



            setup:di:compile


            command.



            Also, try to remove var/cache/* var/page_cache/* var/generation/*



            and run



            setup:upgrade


            command.






            share|improve this answer
























            • I'm in developer mode with the cache disabled. I ran setup:di:compile anyway, and it only moves the error to the PHP log and changes the stack trace a little.

              – andyjv
              Jul 21 '17 at 15:38














            0












            0








            0







            You can try to use



            setup:di:compile


            command.



            Also, try to remove var/cache/* var/page_cache/* var/generation/*



            and run



            setup:upgrade


            command.






            share|improve this answer













            You can try to use



            setup:di:compile


            command.



            Also, try to remove var/cache/* var/page_cache/* var/generation/*



            and run



            setup:upgrade


            command.







            share|improve this answer












            share|improve this answer



            share|improve this answer










            answered Jul 21 '17 at 15:12









            Illia ArefyevIllia Arefyev

            1572315




            1572315













            • I'm in developer mode with the cache disabled. I ran setup:di:compile anyway, and it only moves the error to the PHP log and changes the stack trace a little.

              – andyjv
              Jul 21 '17 at 15:38



















            • I'm in developer mode with the cache disabled. I ran setup:di:compile anyway, and it only moves the error to the PHP log and changes the stack trace a little.

              – andyjv
              Jul 21 '17 at 15:38

















            I'm in developer mode with the cache disabled. I ran setup:di:compile anyway, and it only moves the error to the PHP log and changes the stack trace a little.

            – andyjv
            Jul 21 '17 at 15:38





            I'm in developer mode with the cache disabled. I ran setup:di:compile anyway, and it only moves the error to the PHP log and changes the stack trace a little.

            – andyjv
            Jul 21 '17 at 15:38











            0














            Below command works for me
            In order to bypass "Allowed memory size of error" add memory_limit=-1 before the command.




            php -d memory_limit=-1 bin/magento setup:di:compile





            share|improve this answer








            New contributor




            gurcharan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
            Check out our Code of Conduct.

























              0














              Below command works for me
              In order to bypass "Allowed memory size of error" add memory_limit=-1 before the command.




              php -d memory_limit=-1 bin/magento setup:di:compile





              share|improve this answer








              New contributor




              gurcharan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
              Check out our Code of Conduct.























                0












                0








                0







                Below command works for me
                In order to bypass "Allowed memory size of error" add memory_limit=-1 before the command.




                php -d memory_limit=-1 bin/magento setup:di:compile





                share|improve this answer








                New contributor




                gurcharan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.










                Below command works for me
                In order to bypass "Allowed memory size of error" add memory_limit=-1 before the command.




                php -d memory_limit=-1 bin/magento setup:di:compile






                share|improve this answer








                New contributor




                gurcharan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.









                share|improve this answer



                share|improve this answer






                New contributor




                gurcharan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.









                answered 15 mins ago









                gurcharangurcharan

                111




                111




                New contributor




                gurcharan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.





                New contributor





                gurcharan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.






                gurcharan is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.






























                    draft saved

                    draft discarded




















































                    Thanks for contributing an answer to Magento Stack Exchange!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f184900%2f2-1-reflectionexception-class-does-not-exist%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Magento 2 controller redirect on button click in phtml file

                    Polycentropodidae