Symphony Fatal error: require(): Failed opening re

2019-03-06 08:51发布

问题:

when i enter any type of entry this type of error show up and admin panel not working any more but when i delete the entrys from myphpadmin every things go normal

Warning: require(C:\xampp\htdocs\app\cache\prod/doctrine/orm/Proxies__CG__MediaBundleEntityMedia.php): failed to open stream: No such file or directory in C:\xampp\htdocs\vendor\doctrine\common\lib\Doctrine\Common\Proxy\AbstractProxyFactory.php on line 209

Fatal error: require(): Failed opening required 'C:\xampp\htdocs\app\cache\prod/doctrine/orm/Proxies__CG__MediaBundleEntityMedia.php' (include_path='C:\xampp\php\PEAR') in C:\xampp\htdocs\vendor\doctrine\common\lib\Doctrine\Common\Proxy\AbstractProxyFactory.php on line 209

config_prod.yml

imports:
    - { resource: config.yml }

#framework:
#    validation:
#        cache: validator.mapping.cache.doctrine.apc
#    serializer:
#        cache: serializer.mapping.cache.apc

#doctrine:
 #   orm:
  #      metadata_cache_driver: apc
   #     result_cache_driver: apc
    #    query_cache_driver: apc

monolog:
    handlers:
        main:
            type:         fingers_crossed
            action_level: error
            handler:      nested
        nested:
            type:  stream
            path:  "%kernel.logs_dir%/%kernel.environment%.log"
            level: debug
        console:
            type:  console

confing.yml

imports:
- { resource: parameters.yml }
- { resource: security.yml }
- { resource: services.yml }
- { resource: "@AppBundle/Resources/config/services.yml" }

Put parameters here that don't need to change on each machine where the app is deployed

http://symfony.com/doc/current/best_practices/configuration.html#application-related-configuration

parameters: locale: en files_directory: '%kernel.root_dir%/../public_html/uploads/' files_directory_mp3: '%kernel.root_dir%/../public_html/files/' files_directory_read: '/uploads/' files_directory_read_mp3: '/files/' token_app: "8cve98hty47h2uf0dfg4re7fg0wdhn24ffr3er3reg67yu20" fire_base_key: AIzaSyCWwALLUkDm_ya6EstPhP3ft-tSCPcCfeU framework: translator: { fallbacks: [en] } secret: "%secret%" router: resource: "%kernel.root_dir%/config/routing.yml" strict_requirements: ~ form: ~ csrf_protection: ~ validation: { enable_annotations: true } #serializer: { enable_annotations: true } templating: engines: ['twig','php'] default_locale: "%locale%" trusted_hosts: ~ trusted_proxies: ~ session: # handler_id set to null will use default session handler from php.ini handler_id: ~ fragments: ~ http_method_override: true

Twig Configuration

twig: debug: "%kernel.debug%" strict_variables: "%kernel.debug%"

Doctrine Configuration

doctrine: dbal: driver: pdo_mysql host: "%database_host%" port: "%database_port%" dbname: "%database_name%" user: "%database_user%" password: "%database_password%" charset: UTF8 # if using pdo_sqlite as your database driver: # 1. add the path in parameters.yml # e.g. database_path: "%kernel.root_dir%/data/data.db3" # 2. Uncomment database_path in parameters.yml.dist # 3. Uncomment next line: # path: "%database_path%"

orm:
    auto_generate_proxy_classes: "%kernel.debug%"
    naming_strategy: doctrine.orm.naming_strategy.underscore
    auto_mapping: true
    dql:
        string_functions:
            SHA1: AppBundle\DQL\Sha1

fos_user: db_driver: orm # other valid values are 'mongodb', 'couchdb' and 'propel' firewall_name: main user_class: UserBundle\Entity\User

Swiftmailer Configuration

swiftmailer: transport: "%mailer_transport%" host: "%mailer_host%" username: "%mailer_user%" password: "%mailer_password%" spool: { type: memory } ivory_ck_editor: configs: user_config: language: 'en' width: '100%'
height: '400px' filebrowserBrowseRoute: "media_index" filebrowserBrowseRouteAbsolute: true toolbar: [['Undo','Redo'],[ 'Cut','Copy','Paste'],["Bold","Italic","Underline","TextColor"],['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],['NumberedList', 'BulletedList',"Checkbox"],["BidiLtr","BidiRtl"]] uiColor: "#ffffff" removePlugins: 'elementspath' step_config: language: 'en' width: '100%'
height: '200px' filebrowserBrowseRoute: "media_index" filebrowserBrowseRouteAbsolute: true toolbar: [['Undo','Redo'],[ 'Cut','Copy','Paste'],["Bold","Italic","Underline","TextColor"],['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],['NumberedList', 'BulletedList',"Checkbox"],["BidiLtr","BidiRtl"]] uiColor: "#ffffff" removePlugins: 'elementspath' liip_imagine: resolvers: default: web_path: web_root: %kernel.root_dir%/../public_html/ cache_prefix: uploads/cache loaders: default: filesystem: data_root: %kernel.root_dir%/../public_html/ filter_sets: cache: ~ image_thumb: quality: 100 filters: thumbnail: { size: [300, 300], mode: outbound } image_image: quality: 100 filters: thumbnail: { size: [1024, 720], mode: outbound } album_thumb: quality: 100 filters: thumbnail: { size: [450, 450], mode: outbound } image_thumb_api: quality: 100 filters: thumbnail: { size: [400, 260], mode: outbound }
image: quality: 100 filters: thumbnail: { size: [50000, 50000], mode: outbound }

    video_thumb_api:
        quality: 100
        filters:
            thumbnail: { size: [400, 200], mode: outbound }           

    category_thumb:
        quality: 100
        filters:
            thumbnail: { size: [200, 200], mode: outbound }
    category_thumb_api:
        quality: 100
        filters:
            thumbnail: { size: [100, 100], mode: outbound }
    language_thumb:
        quality: 100
        filters:
            thumbnail: { size: [200, 200], mode: outbound }
    language_thumb_api:
        quality: 100
        filters:
            thumbnail: { size: [100, 100], mode: outbound }
    application_thumb_icon:
        quality: 100
        filters:
            thumbnail: { size: [100, 100], mode: outbound }
    application_thumb_cover:
        quality: 100
        filters:
            thumbnail: { size: [400, 260], mode: outbound }