GithubHelp home page GithubHelp logo

lyn4ever29 / halo-plugin-export-md Goto Github PK

View Code? Open in Web Editor NEW
10.0 10.0 5.0 486 KB

export blogs of halo to markdown

License: GNU General Public License v3.0

JavaScript 0.41% TypeScript 8.25% Vue 15.45% Java 75.88%

halo-plugin-export-md's People

Contributors

chengzhongxue avatar lyn4ever29 avatar ruibaby avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

halo-plugin-export-md's Issues

默认编辑器导出500

默认编辑器导出一篇文章500
日志如下

 WAL file(s) added, 0 removed, 0 recycled; write=0.903 s, sync=0.004 s, total=0.915 s; sync files=7, longest=0.003 s, average=0.001 s; distance=54 kB, estimate=85 kB; lsn=0/C75F2F0, redo lsn=0/C75F2B8
halo         | 2024-03-30T21:56:40.662+08:00  WARN 6 --- [dedElastic-1365] c.l.e.service.impl.ExportServiceImpl     : 写文件:HTML-/root/.halo2/plugins/export2doc_files/export/markdown_post/MySQL Explain使用教程.html
halo         | 2024-03-30T21:56:40.667+08:00 ERROR 6 --- [tor-tcp-epoll-1] a.w.r.e.AbstractErrorWebExceptionHandler : [20726511-22601]  500 Server Error for HTTP GET "/apis/api.plugin.halo.run/v1alpha1/plugins/export2doc/doExport/export_one/f63944f8-4591-45a8-b2cd-b79838253f81"
halo         | 
halo         | java.lang.ClassCastException: io.github.guqing.cloudinary.ImageOptimizerWebFilter$ImageOptimizerResponseDecorator incompatible with org.springframework.http.ZeroCopyHttpOutputMessage
halo         |  at cn.lyn4ever.export2md.rest.ExportController.lambda$fetchHeadContent$2(ExportController.java:86) ~[na:na]
halo         |  Suppressed: reactor.core.publisher.FluxOnAssembly$OnAssemblyException: 
halo         | Error has been observed at the following site(s):
halo         |  *__checkpointrun.halo.app.security.InitializeRedirectionWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointAuthorizationWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointExceptionTranslationWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointLogoutWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointServerRequestCacheWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointSecurityContextServerWebExchangeWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointLogoutPageGeneratingWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointAnonymousAuthenticationWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointSecurityWebFilterChainProxy [DefaultWebFilterChain]
halo         |  *__checkpointTotpAuthenticationFilter [DefaultWebFilterChain]
halo         |  *__checkpointAuthenticationWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointSecurityWebFilterChainProxy [DefaultWebFilterChain]
halo         |  *__checkpointSecurityWebFilterChainProxy [DefaultWebFilterChain]
halo         |  *__checkpointAuthenticationWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointAuthenticationWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointReactorContextWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointCsrfWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointCorsWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointHttpHeaderWriterWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointServerWebExchangeReactorContextWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointorg.springframework.security.web.server.WebFilterChainProxy [DefaultWebFilterChain]
halo         |  *__checkpointrun.halo.oauth.Oauth2Authenticator [DefaultWebFilterChain]
halo         |  *__checkpointrun.halo.oauth.Oauth2AuthorizationRequestRedirectWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointio.github.guqing.cloudinary.ImageOptimizerWebFilter [DefaultWebFilterChain]
halo         |  *__checkpointrun.halo.app.webfilter.AdditionalWebFilterChainProxy [DefaultWebFilterChain]
halo         |  *__checkpointHTTP GET "/apis/api.plugin.halo.run/v1alpha1/plugins/export2doc/doExport/export_one/f63944f8-4591-45a8-b2cd-b79838253f81" [ExceptionHandlingWebHandler]
halo         | Original Stack Trace:
halo         |          at cn.lyn4ever.export2md.rest.ExportController.lambda$fetchHeadContent$2(ExportController.java:86) ~[na:na]
halo         |          at reactor.core.publisher.MonoCallable.call(MonoCallable.java:72) ~[reactor-core-3.6.4.jar:3.6.4]
halo         |          at reactor.core.publisher.FluxSubscribeOnCallable$CallableSubscribeOnSubscription.run(FluxSubscribeOnCallable.java:228) ~[reactor-core-3.6.4.jar:3.6.4]
halo         |          at reactor.core.scheduler.SchedulerTask.call(SchedulerTask.java:68) ~[reactor-core-3.6.4.jar:3.6.4]
halo         |          at reactor.core.scheduler.SchedulerTask.call(SchedulerTask.java:28) ~[reactor-core-3.6.4.jar:3.6.4]
halo         |          at java.base/java.util.concurrent.FutureTask.run(Unknown Source) ~[na:na]
halo         |          at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source) ~[na:na]
halo         |          at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) ~[na:na]
halo         |          at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) ~[na:na]
halo         |          at java.base/java.lang.Thread.run(Unknown Source) ~[na:na]
halo         | 
halod

插件识别Markdown的Front-matter里面的内容发生错误

作者您好,我本人目前是Hexo的用户,写作都是用的markdown,个人也比较喜欢用markdown来编辑文章而不是系统自带的编辑器,之前halo有过Wordpress的导入插件,但是默认导入之后都是用自带的编辑器编辑的,无法切换成markdown,所以一直比较苦恼,最近发现了您开发的这款插件,非常棒,可以让导入的文章也支持markdown编辑,遂让我萌生了迁移博客平台的想法。

不过经过个人测试,插件识别Markdown的Front-matter里面的内容会发生错误,比如我的这篇内容:

image-20240126150827259

---
title: 【好玩儿的Docker项目】10分钟搭建一个功能更强大的图床——Lsky Pro 
date: 2022-06-02 20:18:25.115
updated: 2024-01-18
url: docker-compose-install-lskypro
categories: 
- Docker系列
tags: 
- 图床
---

自动识别的结果是这样的:
image-20240126150919791

url跑到了标题里面,分类目录、标签、发表时间、更新时间等字段无法成功识别。

因为有近240篇markdown的文章导入,一篇一篇改起来工作量会比较大,所以想要恳请是否可以迭代一下插件,使得可以成功识别这些基础字段,非常感谢!

Markdown的属性如何使用

在markdown文件内写了相应的属性,结果导入后被认为是文字,没有将相应的属性注入到对应位置去

导出文章报错

halo version: 2.14
halo-plugin-export-md version: 1.2.4

导出文章报错如下

2024-05-09T17:16:20.982+08:00 ERROR 7 --- [or-tcp-epoll-27] a.w.r.e.AbstractErrorWebExceptionHandler : [31751624-239534]  500 Server Error for HTTP GET "/apis/api.plugin.halo.run/v1alpha1/plugins/export2doc/doExport/export_one/5152aea5-c2e8-4717-8bba-2263d46e19d5"

java.lang.RuntimeException: java.io.FileNotFoundException: /.halo2/plugins/export2doc_files/export/markdown_post/Hello Halo.html (No such file or directory)
        at cn.lyn4ever.export2md.service.impl.ExportServiceImpl.writeContent(ExportServiceImpl.java:227) ~[na:na]
        Suppressed: reactor.core.publisher.FluxOnAssembly$OnAssemblyException:
Error has been observed at the following site(s):
        *__checkpoint ⇢ run.halo.app.security.InitializeRedirectionWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ AuthorizationWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ ExceptionTranslationWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ LogoutWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ ServerRequestCacheWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ SecurityContextServerWebExchangeWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ LogoutPageGeneratingWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ AnonymousAuthenticationWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ SecurityWebFilterChainProxy [DefaultWebFilterChain]
        *__checkpoint ⇢ TotpAuthenticationFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ AuthenticationWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ SecurityWebFilterChainProxy [DefaultWebFilterChain]
        *__checkpoint ⇢ SecurityWebFilterChainProxy [DefaultWebFilterChain]
        *__checkpoint ⇢ AuthenticationWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ AuthenticationWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ ReactorContextWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ CsrfWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ CorsWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ HttpHeaderWriterWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ ServerWebExchangeReactorContextWebFilter [DefaultWebFilterChain]
        *__checkpoint ⇢ org.springframework.security.web.server.WebFilterChainProxy [DefaultWebFilterChain]
        *__checkpoint ⇢ run.halo.app.webfilter.AdditionalWebFilterChainProxy [DefaultWebFilterChain]
        *__checkpoint ⇢ HTTP GET "/apis/api.plugin.halo.run/v1alpha1/plugins/export2doc/doExport/export_one/5152aea5-c2e8-4717-8bba-2263d46e19d5" [ExceptionHandlingWebHandler]
Original Stack Trace:
                at cn.lyn4ever.export2md.service.impl.ExportServiceImpl.writeContent(ExportServiceImpl.java:227) ~[na:na]
                at cn.lyn4ever.export2md.service.impl.ExportServiceImpl.writePost(ExportServiceImpl.java:140) ~[na:na]
                at cn.lyn4ever.export2md.rest.ExportController.lambda$fetchHeadContent$2(ExportController.java:83) ~[na:na]
                at reactor.core.publisher.MonoCallable.call(MonoCallable.java:72) ~[reactor-core-3.6.4.jar:3.6.4]
                at reactor.core.publisher.FluxSubscribeOnCallable$CallableSubscribeOnSubscription.run(FluxSubscribeOnCallable.java:228) ~[reactor-core-3.6.4.jar:3.6.4]
                at reactor.core.scheduler.SchedulerTask.call(SchedulerTask.java:68) ~[reactor-core-3.6.4.jar:3.6.4]
                at reactor.core.scheduler.SchedulerTask.call(SchedulerTask.java:28) ~[reactor-core-3.6.4.jar:3.6.4]
                at java.base/java.util.concurrent.FutureTask.run(Unknown Source) ~[na:na]
                at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source) ~[na:na]
                at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) ~[na:na]
                at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) ~[na:na]
                at java.base/java.lang.Thread.run(Unknown Source) ~[na:na]
Caused by: java.io.FileNotFoundException: /.halo2/plugins/export2doc_files/export/markdown_post/Hello Halo.html (No such file or directory)
        at java.base/java.io.FileOutputStream.open(Unknown Source) ~[na:na]
        at java.base/java.io.FileOutputStream.<init>(Unknown Source) ~[na:na]
        at java.base/java.io.FileOutputStream.<init>(Unknown Source) ~[na:na]
        at java.base/java.io.FileWriter.<init>(Unknown Source) ~[na:na]
        at cn.lyn4ever.export2md.service.impl.ExportServiceImpl.writeContent(ExportServiceImpl.java:175) ~[na:na]
        at cn.lyn4ever.export2md.service.impl.ExportServiceImpl.writePost(ExportServiceImpl.java:140) ~[na:na]
        at cn.lyn4ever.export2md.rest.ExportController.lambda$fetchHeadContent$2(ExportController.java:83) ~[na:na]
        at reactor.core.publisher.MonoCallable.call(MonoCallable.java:72) ~[reactor-core-3.6.4.jar:3.6.4]
        at reactor.core.publisher.FluxSubscribeOnCallable$CallableSubscribeOnSubscription.run(FluxSubscribeOnCallable.java:228) ~[reactor-core-3.6.4.jar:3.6.4]
        at reactor.core.scheduler.SchedulerTask.call(SchedulerTask.java:68) ~[reactor-core-3.6.4.jar:3.6.4]
        at reactor.core.scheduler.SchedulerTask.call(SchedulerTask.java:28) ~[reactor-core-3.6.4.jar:3.6.4]
        at java.base/java.util.concurrent.FutureTask.run(Unknown Source) ~[na:na]
        at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source) ~[na:na]
        at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) ~[na:na]
        at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) ~[na:na]
        at java.base/java.lang.Thread.run(Unknown Source) ~[na:na]

Exception in thread "Thread-228" java.lang.RuntimeException: java.io.FileNotFoundException: /.halo2/plugins/export2doc_files/export/export2doc_20240509172045/Hello Halo.html (No such file or directory)
        at cn.lyn4ever.export2md.service.impl.ExportServiceImpl.writeContent(ExportServiceImpl.java:227)
        at cn.lyn4ever.export2md.service.impl.ExportServiceImpl.writePost(ExportServiceImpl.java:140)
        at cn.lyn4ever.export2md.service.impl.ExportServiceImpl.lambda$runTask$1(ExportServiceImpl.java:88)
        at java.base/java.util.ArrayList.forEach(Unknown Source)
        at cn.lyn4ever.export2md.service.impl.ExportServiceImpl.runTask(ExportServiceImpl.java:87)
        at cn.lyn4ever.export2md.rest.ExportController.lambda$export$0(ExportController.java:65)
        at java.base/java.lang.Thread.run(Unknown Source)
Caused by: java.io.FileNotFoundException: /.halo2/plugins/export2doc_files/export/export2doc_20240509172045/Hello Halo.html (No such file or directory)
        at java.base/java.io.FileOutputStream.open(Unknown Source)
        at java.base/java.io.FileOutputStream.<init>(Unknown Source)
        at java.base/java.io.FileOutputStream.<init>(Unknown Source)
        at java.base/java.io.FileWriter.<init>(Unknown Source)
        at cn.lyn4ever.export2md.service.impl.ExportServiceImpl.writeContent(ExportServiceImpl.java:175)
        ... 6 more

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.